From 03f3a7fddba36c66ffda3533e41cc7eb74520d43 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Fri, 6 May 2022 07:24:07 +0000 Subject: [PATCH] Bug 30703: Remove a few CookieManager warnings Content-Type: text/plain; charset=utf-8 Running Auth.t produces several warnings like: Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 103. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 104. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 112. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 103. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 104. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 112. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 103. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 104. Use of uninitialized value $name in hash element at /usr/share/koha/Koha/CookieManager.pm line 112. Test plan: prove t/CookieManager.t t/db_dependent/Auth.t Signed-off-by: Marcel de Rooy --- Koha/CookieManager.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/Koha/CookieManager.pm b/Koha/CookieManager.pm index d7680d8cc0..018c8068e1 100644 --- a/Koha/CookieManager.pm +++ b/Koha/CookieManager.pm @@ -99,6 +99,7 @@ sub clear_unless { } else { $name = $c; } + next if !$name; if( !$self->{_remove_unless}->{$name} ) { next if $seen->{$name}; -- 2.20.1