summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Speicher <robert@gitlab.com>2016-05-26 21:36:01 +0000
committerYorick Peterse <yorickpeterse@gmail.com>2016-06-02 13:23:06 +0200
commitac98845e7ac25511e9be2107f40efe9944ee9b19 (patch)
tree80518ef2b75ceb9076e92643486029cf8948e789
parent88bb7b51c9972f555916e45ee722d42bb1782a69 (diff)
downloadgitlab-ce-ac98845e7ac25511e9be2107f40efe9944ee9b19.tar.gz
Merge branch 'fix/gitlab-importer-issue' into 'master'
Fix gitlab importer issue Fixed credentials not being called correctly - probably some bad refactoring or search & replace... Fixes https://gitlab.com/gitlab-org/gitlab-ee/issues/565 See merge request !4301
-rw-r--r--CHANGELOG3
-rw-r--r--lib/gitlab/gitlab_import/importer.rb6
2 files changed, 6 insertions, 3 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 6e85317fc52..328ecf59722 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -5,6 +5,9 @@ v 8.8.3
- Fixed potential issue with 2 ci status polling events happening. !3869
- Improve design of Pipeline View. !4230
+v 8.8.3
+ - Fix gitlab importer failing to import new projects due to missing credentials
+
v 8.8.2
- Added remove due date button. !4209
- Fix Error 500 when accessing application settings due to nil disabled OAuth sign-in sources. !4242
diff --git a/lib/gitlab/gitlab_import/importer.rb b/lib/gitlab/gitlab_import/importer.rb
index 3e51c06877e..e32ef8a44c2 100644
--- a/lib/gitlab/gitlab_import/importer.rb
+++ b/lib/gitlab/gitlab_import/importer.rb
@@ -5,9 +5,9 @@ module Gitlab
def initialize(project)
@project = project
- credentials = project.import_data
- if credentials && credentials[:password]
- @client = Client.new(credentials[:password])
+ import_data = project.import_data
+ if import_data && import_data.credentials && import_data.credentials[:password]
+ @client = Client.new(import_data.credentials[:password])
@formatter = Gitlab::ImportFormatter.new
else
raise Projects::ImportService::Error, "Unable to find project import data credentials for project ID: #{@project.id}"