From f31a5b00e86dbba3156c0cff1bfcd251f5cc42da Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 28 Apr 2017 08:48:50 +0100 Subject: [PATCH] BUG 18505: opac-search-history does not respect opacPublic The opac-search-history page was available regardless of the opacPublic setting, this patch corrects that. Test plan, set opacPublic to 'No', test whether opac-search-history page is available when not logged in, note that it is. Apply patch, test whether opac-search-history is still available when not logged in, note that you should be redirected to the login page. Signed-off-by: Katrin Fischer Signed-off-by: Nick Clemens Signed-off-by: Kyle M Hall (cherry picked from commit 94e09b6a186a4a8f1a2a470c41493ad228d0be20) Signed-off-by: Katrin Fischer --- opac/opac-search-history.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opac/opac-search-history.pl b/opac/opac-search-history.pl index 34b0e84c63..da1196b305 100755 --- a/opac/opac-search-history.pl +++ b/opac/opac-search-history.pl @@ -40,7 +40,7 @@ my ($template, $loggedinuser, $cookie) = get_template_and_user( template_name => "opac-search-history.tt", query => $cgi, type => "opac", - authnotrequired => 1, + authnotrequired => ( C4::Context->preference("OpacPublic") ? 1 : 0 ), flagsrequired => {borrowers => 1}, debug => 1, } -- 2.39.5