From d2d250b7ee1b5330ab27baa0dececbd04980fd72 Mon Sep 17 00:00:00 2001 From: Pascal KISSIAN Date: Sun, 13 Sep 2015 17:45:03 +0200 Subject: [PATCH] removed unused variable check which was emitting a notice when a bad config file pathname was specified --- include/functions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/functions.php b/include/functions.php index 2040d52..6d44238 100644 --- a/include/functions.php +++ b/include/functions.php @@ -98,7 +98,7 @@ function check_config_file($filename) // self-explanatory $ok = true; break; } - if (!$ok && $display_warning) fprintf(STDERR,"Warning:[%S] is not a valid yakpro-po config file!%s\tCheck if file is php, and if magic line is present!%s",$filename,PHP_EOL,PHP_EOL); + if (!$ok) fprintf(STDERR,"Warning:[%s] is not a valid yakpro-po config file!%s\tCheck if file is php, and if magic line is present!%s",$filename,PHP_EOL,PHP_EOL); return $ok; } @@ -127,7 +127,7 @@ function remove_directory($path) // self-explanatory if ($entry == ".") continue; if ($entry == "..") continue; - if (is_link("$path/$entry")) unlink("$path/$entry" ); // remove symbolinc links first, to not dereference... + if (is_link("$path/$entry")) unlink("$path/$entry" ); // remove symbolic links first, to not dereference... else if (is_dir ("$path/$entry")) remove_directory("$path/$entry"); else unlink("$path/$entry" ); }