From 6b1902b0b3ff0aec468889ed00e92b59cb2aef48 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Tue, 4 Mar 2025 14:46:12 +0000 Subject: [PATCH] Bug 29410: Resolve warn on numeric ne for two dates Simply, remove the !=0 test. Test for true. Test plan: Restart SIP. Ask item info (SIP 17) on a waiting hold. It must have a hold pickup date. Check that warn disappears with this patch. Signed-off-by: Marcel de Rooy Signed-off-by: Paul Derscheid Signed-off-by: Katrin Fischer (cherry picked from commit f63feea8c621a88f9a2771bad746c7d9f0a95918) Signed-off-by: Baptiste Wojtkowski --- C4/SIP/Sip/MsgType.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/SIP/Sip/MsgType.pm b/C4/SIP/Sip/MsgType.pm index d5a024298a..f0b5aed5be 100644 --- a/C4/SIP/Sip/MsgType.pm +++ b/C4/SIP/Sip/MsgType.pm @@ -1289,10 +1289,10 @@ sub handle_item_information { : timestamp( $item->due_date ); $resp .= add_field( FID_DUE_DATE, $due_date, $server ); } - if ( ( $i = $item->recall_date ) != 0 ) { + if ( $i = $item->recall_date ) { $resp .= add_field( FID_RECALL_DATE, timestamp($i), $server ); } - if ( ( $i = $item->hold_pickup_date ) != 0 ) { + if ( $i = $item->hold_pickup_date ) { $resp .= add_field( FID_HOLD_PICKUP_DATE, timestamp($i), $server ); }