summaryrefslogtreecommitdiff
path: root/lib/gitlab/legacy_github_import/label_formatter.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/legacy_github_import/label_formatter.rb')
-rw-r--r--lib/gitlab/legacy_github_import/label_formatter.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/legacy_github_import/label_formatter.rb b/lib/gitlab/legacy_github_import/label_formatter.rb
index 0b6e4612843..415b1b8878f 100644
--- a/lib/gitlab/legacy_github_import/label_formatter.rb
+++ b/lib/gitlab/legacy_github_import/label_formatter.rb
@@ -20,7 +20,7 @@ module Gitlab
service = ::Labels::FindOrCreateService.new(nil, project, params)
label = service.execute(skip_authorization: true)
- raise ActiveRecord::RecordInvalid.new(label) unless label.persisted?
+ raise ActiveRecord::RecordInvalid, label unless label.persisted?
label
end