1 | <?php |
||
17 | abstract class Exception extends SymfonyHttpException |
||
18 | { |
||
19 | |||
20 | /** |
||
21 | * MessageBag errors. |
||
22 | * |
||
23 | * @var \Illuminate\Support\MessageBag |
||
24 | */ |
||
25 | protected $errors; |
||
26 | |||
27 | /** |
||
28 | * Default status code. |
||
29 | * |
||
30 | * @var int |
||
31 | */ |
||
32 | protected $defaultHttpStatusCode = Response::HTTP_INTERNAL_SERVER_ERROR; |
||
33 | |||
34 | /** |
||
35 | * @var string |
||
36 | */ |
||
37 | protected $environment; |
||
38 | |||
39 | /** |
||
40 | * Exception constructor. |
||
41 | * |
||
42 | * @param null $message |
||
43 | * @param null $errors |
||
44 | * @param null $statusCode |
||
45 | * @param int $code |
||
46 | * @param \Exception|null $previous |
||
47 | * @param array $headers |
||
48 | */ |
||
49 | public function __construct( |
||
91 | |||
92 | /** |
||
93 | * Help developers debug the error without showing these details to the end user. |
||
94 | * Usage: `throw (new MyCustomException())->debug($e)`. |
||
95 | * |
||
96 | * @param $error |
||
97 | * @param $force |
||
98 | * |
||
99 | * @return $this |
||
100 | */ |
||
101 | public function debug($error, $force = false) |
||
113 | |||
114 | /** |
||
115 | * Get the errors message bag. |
||
116 | * |
||
117 | * @return \Illuminate\Support\MessageBag |
||
118 | */ |
||
119 | public function getErrors() |
||
123 | |||
124 | /** |
||
125 | * Determine if message bag has any errors. |
||
126 | * |
||
127 | * @return bool |
||
128 | */ |
||
129 | public function hasErrors() |
||
133 | } |
||
134 |
An attempt at access to an undefined property has been detected. This may either be a typographical error or the property has been renamed but there are still references to its old name.
If you really want to allow access to undefined properties, you can define magic methods to allow access. See the php core documentation on Overloading.