diff options
-rw-r--r-- | lib/gitlab/import_export/relation_factory.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/import_export/relation_factory.rb b/lib/gitlab/import_export/relation_factory.rb index dd7f9e2fd65..0319d7707a8 100644 --- a/lib/gitlab/import_export/relation_factory.rb +++ b/lib/gitlab/import_export/relation_factory.rb @@ -154,7 +154,7 @@ module Gitlab end def remove_encrypted_attributes! - return if relation_class.encrypted_attributes.empty? + return unless relation_class.respond_to?(:encrypted_attributes) && relation_class.encrypted_attributes.any? relation_class.encrypted_attributes.each_key do |key| @relation_hash[key.to_s] = nil |