From 7c14483010b22099b07512399889b8dab182e423 Mon Sep 17 00:00:00 2001 From: Andrew Isherwood Date: Thu, 7 Feb 2019 10:43:51 +0000 Subject: [PATCH] Bug 20581: (follow-up) Passed value to status_alias Now we have overloaded status_alias, we can no longer pass it undef (as it uses that to determine if it's being used as a getter or setter). So we now pass it -1 to indicate it should actually be setting undef (a hack, I know, but what are you going to do...) This patch makes sure ill-request.pl conforms to that. It also fixes the testing of the passed parameter, which was wrong. Signed-off-by: Katrin Fischer Signed-off-by: Katrin Fischer Signed-off-by: Nick Clemens --- ill/ill-requests.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ill/ill-requests.pl b/ill/ill-requests.pl index acbdda29c8..d6be5c89b2 100755 --- a/ill/ill-requests.pl +++ b/ill/ill-requests.pl @@ -174,9 +174,9 @@ if ( $backends_available ) { $request->price_paid($params->{price_paid}); $request->notesopac($params->{notesopac}); $request->notesstaff($params->{notesstaff}); - my $alias = ($params->{status_alias}) ? + my $alias = (length $params->{status_alias} > 0) ? $params->{status_alias} : - undef; + "-1"; $request->status_alias($alias); $request->store; my $backend_result = { -- 2.39.5