Skip to content

Commit

Permalink
Fix Sequel query to match both creator an subject
Browse files Browse the repository at this point in the history
  • Loading branch information
payten committed Oct 15, 2020
1 parent f13846b commit 4a39dc8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/model/ladybird_export.rb
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ def prepare_related_agents
.and(Sequel.|({:name_corporate_entity__is_display_name => 1}, {:name_corporate_entity__is_display_name => nil}))
.and(Sequel.|({:name_family__is_display_name => 1}, {:name_family__is_display_name => nil}))
.and(Sequel.|({:name_software__is_display_name => 1}, {:name_software__is_display_name => nil}))
.and(Sequel.|({:linked_agents_rlshp__role_id => creator_enum_id, :linked_agents_rlshp__role_id => subject_enum_id}))
.and(Sequel.|({:linked_agents_rlshp__role_id => [creator_enum_id, subject_enum_id]}))
.select(Sequel.as(:archival_object__id, :archival_object_id),
Sequel.as(:linked_agents_rlshp__role_id, :role_id),
Sequel.as(:name_person__sort_name, :person),
Expand Down

0 comments on commit 4a39dc8

Please sign in to comment.