From a3a174201d6cdf7a29c00daec9d70d739423da32 Mon Sep 17 00:00:00 2001 From: Thomas Berezansky Date: Thu, 23 Jan 2014 12:05:08 -0500 Subject: [PATCH] LP#1296937: Call _items functions with ids_only parameter So that we don't do full lookups of titles when we only care about counts. Signed-off-by: Thomas Berezansky Signed-off-by: Galen Charlton --- Sip/MsgType.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Sip/MsgType.pm b/Sip/MsgType.pm index 6fb4793..4892ca1 100644 --- a/Sip/MsgType.pm +++ b/Sip/MsgType.pm @@ -937,12 +937,12 @@ sub handle_patron_info { $lang = $patron->language if $patron->language; $resp .= $lang . Sip::timestamp(); - $resp .= add_count('patron_info/hold_items', scalar @{$patron->hold_items }); - $resp .= add_count('patron_info/overdue_items', scalar @{$patron->overdue_items}); - $resp .= add_count('patron_info/charged_items', scalar @{$patron->charged_items}); - $resp .= add_count('patron_info/fine_items', scalar @{$patron->fine_items }); - $resp .= add_count('patron_info/recall_items', scalar @{$patron->recall_items }); - $resp .= add_count('patron_info/unavail_holds', scalar @{$patron->unavail_holds}); + $resp .= add_count('patron_info/hold_items', scalar @{$patron->hold_items(undef,undef,1) }); + $resp .= add_count('patron_info/overdue_items', scalar @{$patron->overdue_items(undef,undef,1)}); + $resp .= add_count('patron_info/charged_items', scalar @{$patron->charged_items(undef,undef,1)}); + $resp .= add_count('patron_info/fine_items', scalar @{$patron->fine_items(undef,undef,1) }); + $resp .= add_count('patron_info/recall_items', scalar @{$patron->recall_items(undef,undef,1) }); + $resp .= add_count('patron_info/unavail_holds', scalar @{$patron->unavail_holds(undef,undef,1)}); # while the patron ID we got from the SC is valid, let's # use the one returned from the ILS, just in case... -- 2.11.0