Skip to content
This repository has been archived by the owner on May 28, 2024. It is now read-only.

Commit

Permalink
desc_metadata_indexer: avoid error when genre value is nil
Browse files Browse the repository at this point in the history
  • Loading branch information
ndushay authored Aug 8, 2022
1 parent 74733db commit 2aee64b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/indexers/descriptive_metadata_indexer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ def sw_format

return resource_type_formats if resource_type_formats == ['Book']

genre_formats = flat_forms_for('genre').map { |form| form.value.capitalize }.uniq
genre_formats = flat_forms_for('genre').map { |form| form.value&.capitalize }.uniq

(resource_type_formats + genre_formats).presence
end
Expand Down

0 comments on commit 2aee64b

Please sign in to comment.