mirror of
https://github.com/pelican-dev/panel.git
synced 2025-05-20 01:44:45 +02:00
Add http status code enum
This commit is contained in:
parent
939b7354e4
commit
d0d388534b
31
app/Enums/HttpStatusCode.php
Normal file
31
app/Enums/HttpStatusCode.php
Normal file
@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace App\Enums;
|
||||
|
||||
enum HttpStatusCode: int
|
||||
{
|
||||
// Client
|
||||
case BadRequest = 400;
|
||||
case Unauthorized = 401;
|
||||
case Forbidden = 403;
|
||||
case NotFound = 404;
|
||||
case MethodNotAllowed = 405;
|
||||
case NotAcceptable = 406;
|
||||
case ProxyAuthenticationRequired = 407;
|
||||
case RequestTimeout = 408;
|
||||
case Conflict = 409;
|
||||
case Gone = 410;
|
||||
case LengthRequired = 411;
|
||||
case PreconditionFailed = 412;
|
||||
case PayloadTooLarge = 413;
|
||||
case UriTooLong = 414;
|
||||
case UnsupportedMediaType = 415;
|
||||
|
||||
// Server
|
||||
case InternalServerError = 500;
|
||||
case NotImplemented = 501;
|
||||
case BadGateway = 502;
|
||||
case ServiceUnavailable = 503;
|
||||
case GatewayTimeout = 504;
|
||||
case HTTPVersionNotSupported = 505;
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user