summaryrefslogtreecommitdiff
path: root/app/controllers/import
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2016-05-02 11:29:21 +0200
committerJames Lopez <james@jameslopez.es>2016-05-02 11:29:21 +0200
commit07ab6c2e26a36734ad29ae037810c14d2be7ec8b (patch)
tree3e3b552bce3a61718a8565a39be3c2111623506b /app/controllers/import
parent7ebf22e0024f457238090c3545b8acafae0e1a6f (diff)
downloadgitlab-ce-07ab6c2e26a36734ad29ae037810c14d2be7ec8b.tar.gz
refactoring and fixing a bunch of stuff
Diffstat (limited to 'app/controllers/import')
-rw-r--r--app/controllers/import/gitlab_projects_controller.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/app/controllers/import/gitlab_projects_controller.rb b/app/controllers/import/gitlab_projects_controller.rb
index b141b5f472a..f8d4bcff55a 100644
--- a/app/controllers/import/gitlab_projects_controller.rb
+++ b/app/controllers/import/gitlab_projects_controller.rb
@@ -12,13 +12,7 @@ class Import::GitlabProjectsController < Import::BaseController
end
def status
- @repos = client.projects
- @incompatible_repos = client.incompatible_projects
- @already_added_projects = current_user.created_projects.where(import_type: "gitlab_project")
- already_added_projects_names = @already_added_projects.pluck(:import_source)
-
- @repos.to_a.reject!{ |repo| already_added_projects_names.include? "#{repo["owner"]}/#{repo["slug"]}" }
end
def jobs
@@ -39,6 +33,8 @@ class Import::GitlabProjectsController < Import::BaseController
tmp_file: File.expand_path(file.path),
namespace_id: namespace_id,
project_path: path)
+
+ redirect_to status_import_gitlab_project_path
end
private