芝麻web文件管理V1.00
编辑当前文件:/home/royashxg/public_html/wp-content/plugins/fluent-smtp/app/Hooks/Handlers/ExceptionHandler.php
'handleForbiddenException', 'FluentMail\Includes\Support\ValidationException' => 'handleValidationException' ]; public function handle($e) { foreach ($this->handlers as $key => $value) { if ($e instanceof $key) { return $this->{$value}($e); } } } public function handleForbiddenException($e) { wp_send_json_error([ 'message' => $e->getMessage() ], $e->getCode() ?: 403); } public function handleValidationException($e) { wp_send_json_error([ 'message' => $e->getMessage(), 'errors' => $e->errors() ], $e->getCode() ?: 422); } }