catchAdmin/modules/Permissions/Exceptions/PermissionForbidden.php
2023-01-12 10:42:38 +08:00

21 lines
403 B
PHP

<?php
namespace Modules\Permissions\Exceptions;
use Catch\Enums\Code;
use Catch\Exceptions\CatchException;
use Symfony\Component\HttpFoundation\Response;
class PermissionForbidden extends CatchException
{
protected $message = 'permission forbidden';
protected $code = Code::PERMISSION_FORBIDDEN;
public function statusCode(): int
{
return Response::HTTP_FORBIDDEN;
}
}