Skip to content

Commit

Permalink
handle ror id not found. #348
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Oct 10, 2019
1 parent d821794 commit 0e6c10a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/concerns/facetable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def facet_by_affiliation(arr)

arr.map do |hsh|
{ "id" => hsh["key"],
"title" => affiliations.find { |a| a["id"] == hsh["key"] }.to_h["name"],
"title" => affiliations.find { |a| a["id"] == hsh["key"] }.to_h["name"] || hsh["key"],
"count" => hsh["doc_count"] }
end
end
Expand Down

0 comments on commit 0e6c10a

Please sign in to comment.