Revert "fix: resolve PHPStan static analysis warnings"

This reverts commit 2d3e4b4a95.
This commit is contained in:
xboard
2025-04-14 21:23:08 +08:00
parent 2d3e4b4a95
commit db235c10e8
84 changed files with 1190 additions and 2330 deletions
+2 -15
View File
@@ -45,16 +45,9 @@ class HookManager
* @param mixed ...$args 其他参数
* @return mixed
*/
public static function filter(string $hook, mixed $value, mixed ...$args): mixed
public static function filter(string $hook, mixed $value): mixed
{
if (!self::hasHook($hook)) {
return $value;
}
/** @phpstan-ignore-next-line */
$result = Eventy::filter($hook, $value, ...$args);
return $result;
return Eventy::filter($hook, $value);
}
/**
@@ -95,10 +88,4 @@ class HookManager
Eventy::removeAction($hook, $callback);
Eventy::removeFilter($hook, $callback);
}
private static function hasHook(string $hook): bool
{
// Implementation of hasHook method
return true; // Placeholder return, actual implementation needed
}
}