Bugzilla – Attachment 166847 Details for
Bug 34838
The ILL module and tests generate warnings
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[23.11.x] Bug 34838: Only call strings_map if status_alias is not undef in status_alias cycle
2311x-Bug-34838-Only-call-stringsmap-if-statusalia.patch (text/plain), 1.40 KB, created by
Tomás Cohen Arazi (tcohen)
on 2024-05-16 20:34:45 UTC
(
hide
)
Description:
[23.11.x] Bug 34838: Only call strings_map if status_alias is not undef in status_alias cycle
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2024-05-16 20:34:45 UTC
Size:
1.40 KB
patch
obsolete
>From c56fdcecaac681ed3db23f544a2fad93d20dd1df Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Date: Tue, 26 Sep 2023 09:33:08 +0000 >Subject: [PATCH] [23.11.x] Bug 34838: Only call strings_map if status_alias is > not undef in status_alias cycle > >Because its highly likely that at least one request will have status_alias null in the database, the select MAX query will always return at least one result with NULL status_alias, throwing a warning, so we skip that > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > Koha/Illbackend.pm | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/Koha/Illbackend.pm b/Koha/Illbackend.pm >index ab31d054950..6d95b5e2a72 100644 >--- a/Koha/Illbackend.pm >+++ b/Koha/Illbackend.pm >@@ -88,9 +88,9 @@ sub existing_statuses { > } > ); > while ( my $request = $ill_requests->next ) { >- my $status_data = $request->strings_map; >+ my $status_data = $request->status_alias ? $request->strings_map : undef; > >- if ( $status_data->{status_alias} ) { >+ if ( $status_data && $status_data->{status_alias} ) { > push @data, { > $status_data->{status_alias}->{str} ? ( str => $status_data->{status_alias}->{str} ) > : $status_data->{status_alias}->{code} ? ( str => $status_data->{status_alias}->{code} ) >-- >2.45.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 34838
:
156178
|
156200
|
156201
|
156202
|
156204
|
156217
|
156218
|
156219
|
156220
|
166841
|
166842
|
166843
|
166844
|
166845
|
166846
| 166847 |
166848
|
166849
|
166850
|
166851
|
166852
|
166853
|
166854
|
166855
|
167193
|
167194
|
167211
|
167212
|
167213
|
167214
|
167215
|
167216