summaryrefslogtreecommitdiff
path: root/app/controllers/groups/application_controller.rb
diff options
context:
space:
mode:
authorValery Sizov <vsv2711@gmail.com>2015-03-12 17:08:48 +0200
committerValery Sizov <vsv2711@gmail.com>2015-03-12 17:08:48 +0200
commit0b38c3e04138984123592da78ad78c79fdeaec3d (patch)
tree5702c6a76a4492542ea84ca1d2dae21584413db3 /app/controllers/groups/application_controller.rb
parent3f823068e1f6e3e88d6631de60d9aaf9ecd5e6f9 (diff)
downloadgitlab-ce-0b38c3e04138984123592da78ad78c79fdeaec3d.tar.gz
group controller refactoring
Diffstat (limited to 'app/controllers/groups/application_controller.rb')
-rw-r--r--app/controllers/groups/application_controller.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/app/controllers/groups/application_controller.rb b/app/controllers/groups/application_controller.rb
new file mode 100644
index 00000000000..7f27f2bb734
--- /dev/null
+++ b/app/controllers/groups/application_controller.rb
@@ -0,0 +1,10 @@
+class Groups::ApplicationController < ApplicationController
+
+ private
+
+ def authorize_admin_group!
+ unless can?(current_user, :manage_group, group)
+ return render_404
+ end
+ end
+end