Commit d6c181c3 authored by Mike Kozono's avatar Mike Kozono

Fix temporary class definition

Before this change, the perform method was using the codebase's
PackageFile class directly.
parent e73e2ef1
...@@ -11,10 +11,12 @@ module Gitlab ...@@ -11,10 +11,12 @@ module Gitlab
class SetNullPackageFilesFileStoreToLocalValue class SetNullPackageFilesFileStoreToLocalValue
LOCAL_STORE = 1 # equal to ObjectStorage::Store::LOCAL LOCAL_STORE = 1 # equal to ObjectStorage::Store::LOCAL
module Packages
# Temporary AR class for package files # Temporary AR class for package files
class PackageFile < ActiveRecord::Base class PackageFile < ActiveRecord::Base
self.table_name = 'packages_package_files' self.table_name = 'packages_package_files'
end end
end
def perform(start_id, stop_id) def perform(start_id, stop_id)
Packages::PackageFile.where(file_store: nil, id: start_id..stop_id).update_all(file_store: LOCAL_STORE) Packages::PackageFile.where(file_store: nil, id: start_id..stop_id).update_all(file_store: LOCAL_STORE)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment