summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2016-06-15 09:08:33 +0200
committerJames Lopez <james@jameslopez.es>2016-06-15 09:08:33 +0200
commit7019a19b8c5ef3e340a04ff7870f31ac00689ca3 (patch)
tree15fe635846595faea83a8e050e41bbcf036eb65d
parent8922712693a57d6c65620d03599fe7c4b4f84119 (diff)
downloadgitlab-ce-7019a19b8c5ef3e340a04ff7870f31ac00689ca3.tar.gz
cleanup namespace check now done by service
-rw-r--r--app/controllers/import/gitlab_projects_controller.rb11
1 files changed, 0 insertions, 11 deletions
diff --git a/app/controllers/import/gitlab_projects_controller.rb b/app/controllers/import/gitlab_projects_controller.rb
index 1de4c4828d2..d63dd64b728 100644
--- a/app/controllers/import/gitlab_projects_controller.rb
+++ b/app/controllers/import/gitlab_projects_controller.rb
@@ -1,6 +1,5 @@
class Import::GitlabProjectsController < Import::BaseController
before_action :verify_gitlab_project_import_enabled
- before_action :verify_project_and_namespace_access
def new
@namespace_id = project_params[:namespace_id]
@@ -36,16 +35,6 @@ class Import::GitlabProjectsController < Import::BaseController
project_params[:file].respond_to?(:read)
end
- def verify_project_and_namespace_access
- unless namespace_access?
- render_403
- end
- end
-
- def namespace_access?
- can?(current_user, :create_projects, Namespace.find(project_params[:namespace_id]))
- end
-
def verify_gitlab_project_import_enabled
render_404 unless gitlab_project_import_enabled?
end