From e43f4871571f45cc136a67720708fe8b440d0cae Mon Sep 17 00:00:00 2001 From: Graham Christensen Date: Tue, 14 Dec 2021 10:24:53 -0500 Subject: [PATCH] perlcritic: return undef in list context too --- src/lib/Hydra/Helper/Nix.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/Hydra/Helper/Nix.pm b/src/lib/Hydra/Helper/Nix.pm index a8ba1ff3..9ecb4d7a 100644 --- a/src/lib/Hydra/Helper/Nix.pm +++ b/src/lib/Hydra/Helper/Nix.pm @@ -396,7 +396,7 @@ sub pathIsInsidePrefix { # ‘..’ should not take us outside of the prefix. if ($c eq "..") { - return if length($cur) <= length($prefix); + return undef if length($cur) <= length($prefix); $cur =~ s/\/[^\/]*$// or die; # remove last component next; }