Add system status displays for Minio and Redis, and enhance backup configuration
This commit is contained in:
@@ -679,9 +679,17 @@ trait route_t
|
||||
global $router;
|
||||
// Wrap the original callback so we can expose the matched route template to fromRoute()
|
||||
$self = $this;
|
||||
$wrapped = function () use ($callback, $route, $self) {
|
||||
$wrapped = function () use ($callback, $route, $method, $self) {
|
||||
// Set the current route template for parameter extraction
|
||||
$self->__current_route_template = $route;
|
||||
try {
|
||||
if (defined('WD') && is_file(WD . '/classes/security_policy_service.php')) {
|
||||
require_once WD . '/classes/security_policy_service.php';
|
||||
(new \classes\security_policy_service())->inspectRequest($route, $method);
|
||||
}
|
||||
} catch (\Throwable $throwable) {
|
||||
error_log('[security_policy_service] request inspection failed: ' . $throwable->getMessage());
|
||||
}
|
||||
// Execute the original callback
|
||||
$callback();
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user