Skip to content

Commit

Permalink
Merge pull request #561 from UCLALibrary/fix-clean_tasks
Browse files Browse the repository at this point in the history
Fix clean tasks
  • Loading branch information
sourcefilter authored Apr 6, 2019
2 parents a6f0e57 + 8b0023a commit 8b32222
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ inherit_gem:
AllCops:
TargetRubyVersion: 2.4

Metrics/AbcSize:
Enabled: true
Exclude:
- 'app/importers/californica_csv_cleaner.rb'

Metrics/ClassLength:
Enabled: true
Exclude:
Expand Down
1 change: 1 addition & 0 deletions app/importers/californica_csv_cleaner.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ def clean
ark = Ark.ensure_prefix(ark)
Work.where(identifier: ark).each { |work| work&.destroy! }
Work.where(ark_ssi: ark).each { |work| work&.destroy! }
Work.where(local_identifier: item.mapper.metadata["AltIdentifier.local"]).each { |work| work&.destroy! }
end

# info_stream << "Actually processed #{actual_records_processed} records"
Expand Down

0 comments on commit 8b32222

Please sign in to comment.