Typo fixed
This commit is contained in:
parent
a9f8b74a95
commit
99059f54df
1 changed files with 2 additions and 2 deletions
|
|
@ -9,7 +9,7 @@ namespace :debshots do
|
||||||
Rails.logger.info "Removing packages with 'nil' screenshots"
|
Rails.logger.info "Removing packages with 'nil' screenshots"
|
||||||
|
|
||||||
Screenshot.where(image_fingerprint: nil).each do |ss|
|
Screenshot.where(image_fingerprint: nil).each do |ss|
|
||||||
Rails.logger.info "Destroying screenshots #{ss.id} of package #{ss.package.name} that has nil data"
|
Rails.logger.info "Destroying screenshot #{ss.id} of package #{ss.package.name} that has nil data"
|
||||||
ss.destroy
|
ss.destroy
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -21,7 +21,7 @@ namespace :debshots do
|
||||||
# Look again for screenshots of this fingerprint.
|
# Look again for screenshots of this fingerprint.
|
||||||
# This extra step may seem stupid but the above query lead to package_id=NULL results sometimes.
|
# This extra step may seem stupid but the above query lead to package_id=NULL results sometimes.
|
||||||
del = Screenshot.find_by(image_fingerprint: ss.image_fingerprint)
|
del = Screenshot.find_by(image_fingerprint: ss.image_fingerprint)
|
||||||
Rails.logger.info "Destroying duplicate screenshots #{del.id} of package #{del.package.name}"
|
Rails.logger.info "Destroying duplicate screenshot #{del.id} of package #{del.package.name}"
|
||||||
del.destroy
|
del.destroy
|
||||||
destroyed += 1
|
destroyed += 1
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue