class
Illuminate
/
Auth
/
Access
/
AuthorizationException
AuthorizationException
Extends
Properties
protected
$status int|null
The HTTP response status code.
Default: null
Methods
public
__construct ( $message , $code , Throwable $previous ) : void
Create a new authorization exception instance.
Parameters
- $message string|null
- $code mixed
- $previous Throwable |null
public
setResponse ( $response ) : $this
Set the response from the gate.
Parameters
- $response Response
public
withStatus ( $status ) : $this
Set the HTTP response status code.
Parameters
- $status int|null
public
asNotFound ( ) : $this
Set the HTTP response status code to 404.
public
hasStatus ( ) : bool
Determine if the HTTP status code has been set.
public
status ( ) : int|null
Get the HTTP status code.