From e692dfc18a06a515d908178d272cf3a4343ae88e Mon Sep 17 00:00:00 2001 From: Chris Nighswonger Date: Thu, 28 Jan 2010 14:49:29 -0500 Subject: [PATCH] Bugfix: Stop opac/opac-detail.pl from filling the log with pesky warns Signed-off-by: Galen Charlton --- opac/opac-detail.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl index f0a7288445..9af15a8aab 100755 --- a/opac/opac-detail.pl +++ b/opac/opac-detail.pl @@ -585,9 +585,9 @@ if (C4::Context->preference('TagsEnabled') and $tag_quantity = C4::Context->pref #Search for title in links if (my $search_for_title = C4::Context->preference('OPACSearchForTitleIn')){ - $search_for_title =~ s/{AUTHOR}/$dat->{author}/g; - $search_for_title =~ s/{TITLE}/$dat->{title}/g; - $search_for_title =~ s/{ISBN}/$isbn/g; + $dat->{author} ? $search_for_title =~ s/{AUTHOR}/$dat->{author}/g : $search_for_title =~ s/{AUTHOR}//g; + $dat->{title} ? $search_for_title =~ s/{TITLE}/$dat->{title}/g : $search_for_title =~ s/{TITLE}//g; + $isbn ? $search_for_title =~ s/{ISBN}/$isbn/g : $search_for_title =~ s/{ISBN}//g; $template->param('OPACSearchForTitleIn' => $search_for_title); } -- 2.39.5