diff options
author | Michael Kozono <mkozono@gmail.com> | 2018-02-21 21:04:42 +0300 |
---|---|---|
committer | Michael Kozono <mkozono@gmail.com> | 2018-02-21 21:04:42 +0300 |
commit | 0c357ac83b941e3a3b5d13e8430ec555b384b967 (patch) | |
tree | 6c387ce935bd0079051410b59a14bbd309d77190 /lib | |
parent | 3f017f07ee27a90984255948f7979390b17e20ae (diff) |
Use convenient Rails helper
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/background_migration/populate_untracked_uploads.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/background_migration/populate_untracked_uploads.rb b/lib/gitlab/background_migration/populate_untracked_uploads.rb index c5415bf0f9a..9232f20a063 100644 --- a/lib/gitlab/background_migration/populate_untracked_uploads.rb +++ b/lib/gitlab/background_migration/populate_untracked_uploads.rb @@ -83,7 +83,7 @@ module Gitlab end ids.each do |model_type, model_ids| - model_class = Object.const_get("Gitlab::BackgroundMigration::PopulateUntrackedUploadsDependencies::#{model_type}") + model_class = "Gitlab::BackgroundMigration::PopulateUntrackedUploadsDependencies::#{model_type}".constantize found_ids = model_class.where(id: model_ids.uniq).pluck(:id) deleted_ids = ids[model_type] - found_ids ids[model_type] = deleted_ids |