Bug 15128 - (QA Followup) Don't get patrons suggestions if limit not set

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
Nick Clemens 2016-07-01 11:39:00 -04:00 committed by Kyle M Hall
parent 074a3ee338
commit 7cde3e216b
1 changed files with 1 additions and 1 deletions

View File

@ -113,7 +113,7 @@ if ( $op eq 'else' ) {
}
my $patrons_pending_suggestions_count = 0;
if ( $borrowernumber ) {
if ( $borrowernumber && C4::Context->preference("MaxOpenSuggestions") ne '' ) {
$patrons_pending_suggestions_count = scalar @{ SearchSuggestion( { suggestedby => $borrowernumber, STATUS => 'ASKED' } ) } ;
}