fix conditional to skip unchanged vars
Graham Knop [Wed, 20 Nov 2013 05:35:44 +0000 (00:35 -0500)]
lib/local/lib.pm

index 9a8e93f..f1a6dd6 100644 (file)
@@ -321,8 +321,11 @@ sub environment_vars_string_for {
         && ${$value->[0]} eq $name) {
       next;
     }
-    if (!ref $value
-        && defined $value ? $value eq $ENV{$name} : !defined $ENV{$name}
+    if (
+        !ref $value
+        and defined $value
+          ? (defined $ENV{$name} && $value eq $ENV{$name})
+          : !defined $ENV{$name}
     ) {
       next;
     }