Skip to content

Commit

Permalink
Revert "[i30] - port over rake tasks from LV (#47)" (#69)
Browse files Browse the repository at this point in the history
* Revert "[i30] - port over rake tasks from LV (#47)"

This reverts commit 53fddb7.

* revert back to main

* lint: rubocop fix
  • Loading branch information
Shana Moore authored Jan 17, 2023
1 parent 657f470 commit ecd73c0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 47 deletions.
20 changes: 9 additions & 11 deletions lib/tasks/set_child_works.rake
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,17 @@ namespace :iiif_print do
desc 'Make sure all child work models have the correct attribute'
task is_child_attribute: [:environment] do
Account.find_each do |account|
begin
switch!(account.cname) if defined? Account
puts "********************** switched to #{account.cname} **********************"
Hyrax.config.curation_concerns.each do |cc|
puts "********************** checking #{cc}s **********************"
next if cc.count.zero?
switch!(account.cname) if defined? Account
puts "********************** switched to #{account.cname} **********************"
Hyrax.config.curation_concerns.each do |cc|
puts "********************** checking #{cc}s **********************"
next if cc.count.zero?

cc.find_each(&:save)
end
rescue StandardError
puts "********************** failed to update account #{account.cname} **********************"
next
cc.find_each(&:save)
end
rescue StandardError
puts "********************** failed to update account #{account.cname} **********************"
next
end
end
end
Expand Down
36 changes: 0 additions & 36 deletions lib/tasks/set_parent_thumbnail.rake

This file was deleted.

0 comments on commit ecd73c0

Please sign in to comment.