We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d2cf97d commit 6427be1Copy full SHA for 6427be1
src/Bramus/Router/Router.php
@@ -367,11 +367,11 @@ public function trigger404($match = null){
367
++$numHandled;
368
}
369
370
- if($numHandled == 0 and $this->notFoundCallback['/']) {
371
- $this->invoke($this->notFoundCallback['/']);
372
- } elseif ($numHandled == 0) {
373
- header($_SERVER['SERVER_PROTOCOL'] . ' 404 Not Found');
374
- }
+ }
+ if (($numHandled == 0) && (isset($this->notFoundCallback['/']))) {
+ $this->invoke($this->notFoundCallback['/']);
+ } elseif ($numHandled == 0) {
+ header($_SERVER['SERVER_PROTOCOL'] . ' 404 Not Found');
375
376
377
0 commit comments