diff --git a/src/Util/Common.php b/src/Util/Common.php index f34ed16101..43fa697917 100644 --- a/src/Util/Common.php +++ b/src/Util/Common.php @@ -1,6 +1,7 @@ . + // }}} /** @@ -104,15 +106,15 @@ abstract class Common // $paths[basename(common_config($cat, 'path'))] = true; // } - // return in_array($str, array_keys($paths)); + // return in_arry($str, array_keys($paths)); } /** * Remove keys from the _values_ of $keys from the array $from */ - public static function array_remove_keys(array $from, array $keys, bool $strict = false) + public static function arrayRemoveKeys(array $from, array $keys, bool $strict = false) { - return F\filter($from, function ($e) use ($keys, $strict) { return in_array($e, $keys, $strict); }); + return F\filter($from, function ($_, $key) use ($keys, $strict) { return !in_array($key, $keys, $strict); }); } /**