Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Fix Bulkrax undefined field b error #577

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions app/parsers/bulkrax/application_parser_decorator.rb
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider removing the logger

Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module Bulkrax
module ApplicationParserDecorator
def work_identifier_search_field
@work_identifier_search_field ||= Array.wrap(get_field_mapping_hash_for('source_identifier')
&.values
&.first
&.[]('search_field'))&.first&.to_s || "#{work_identifier}_sim"
end
end
end

Bulkrax::ApplicationParser.prepend(Bulkrax::ApplicationParserDecorator)
Loading