Bug 31535: Fix warning - uninitialized value for location
In Koha/Item.pm line 169 (line number has been changed) Test plan: You need location to be NULL when storing. Otherwise follow this reasoning: What happens when location is undefined? It is autovivified to empty string in the string compare (ne), so not equal to CART and PROC. The subcondition is true before and after this patch. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Joonas Kylmälä <joonas.kylmala@iki.fi> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
parent
8ddec91211
commit
62fa4937ce
1 changed files with 1 additions and 2 deletions
|
@ -179,8 +179,7 @@ sub store {
|
|||
|
||||
|
||||
if ( exists $updated_columns{location}
|
||||
and $self->location ne 'CART'
|
||||
and $self->location ne 'PROC'
|
||||
and ( !defined($self->location) or $self->location !~ /^(CART|PROC)$/ )
|
||||
and not exists $updated_columns{permanent_location} )
|
||||
{
|
||||
$self->permanent_location( $self->location );
|
||||
|
|
Loading…
Reference in a new issue