feat : exception

This commit is contained in:
2024-11-12 11:45:49 +08:00
parent 1fa2e83822
commit 7fbce21622
2 changed files with 7 additions and 1 deletions

View File

@@ -2,9 +2,14 @@
namespace App\Exception;
use App\Constants\ReturnCode;
use Hyperf\Server\Exception\ServerException;
class ErrException extends ServerException
{
/**
* 重写抛出错误的状态码
* @var int
*/
protected $code = ReturnCode::ERROR;
}