summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2016-06-14 10:55:24 +0200
committerJames Lopez <james@jameslopez.es>2016-06-14 10:55:24 +0200
commit279412f90a58b2bfa939e82c2f90aa0cac2c715b (patch)
tree32df1c945afaa1f3dccea1144a62970d7144c8b9
parent77794579078a9c65a4e9ee4fa8d94113104f69b3 (diff)
downloadgitlab-ce-279412f90a58b2bfa939e82c2f90aa0cac2c715b.tar.gz
updated relation_factory based on MR feedback
-rw-r--r--lib/gitlab/import_export/relation_factory.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/import_export/relation_factory.rb b/lib/gitlab/import_export/relation_factory.rb
index 5f12caa8981..4e4ce4f14a9 100644
--- a/lib/gitlab/import_export/relation_factory.rb
+++ b/lib/gitlab/import_export/relation_factory.rb
@@ -57,11 +57,11 @@ module Gitlab
author = @relation_hash.delete('author')
- update_note_for_missing_author(author['name']) if can_update_notes?
+ update_note_for_missing_author(author['name']) if missing_author?
end
- def can_update_notes?
- (admin_user? && @members_mapper.missing_author_ids.include?(old_author_id)) || !admin_user?
+ def missing_author?
+ !admin_user? || @members_mapper.missing_author_ids.include?(old_author_id)
end
def missing_author_note(updated_at, author_name)