@@ -, +, @@ Koha::Biblio->get_components_query Host-item=(MyTitle = Mysubtitle) at /usr/share/koha/lib/C4/Search.pm line 245." --- Koha/Biblio.pm | 2 +- t/db_dependent/Koha/Biblio.t | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) --- a/Koha/Biblio.pm +++ a/Koha/Biblio.pm @@ -595,7 +595,7 @@ sub get_components_query { my $cleaned_title = $marc->subfield('245', "a"); $cleaned_title =~ tr|/||; $cleaned_title = $builder->clean_search_term($cleaned_title); - $searchstr = "Host-item:($cleaned_title)"; + $searchstr = qq#Host-item:("$cleaned_title")#; } return $searchstr; --- a/t/db_dependent/Koha/Biblio.t +++ a/t/db_dependent/Koha/Biblio.t @@ -569,7 +569,7 @@ subtest 'get_components_query' => sub { my $record = $biblio->metadata->record; t::lib::Mocks::mock_preference( 'UseControlNumber', '0' ); - is($biblio->get_components_query, "Host-item:(Some boring read)", "UseControlNumber disabled"); + is($biblio->get_components_query, 'Host-item:("Some boring read")', "UseControlNumber disabled"); t::lib::Mocks::mock_preference( 'UseControlNumber', '1' ); my $marc_001_field = MARC::Field->new('001', $biblionumber); --