Skip to content

Commit

Permalink
Fix issue #2391 CodeIgniter::display404errors()
Browse files Browse the repository at this point in the history
``CodeIgniter::display404errors`` calls Call to ``CodeIgniter::gatherOutput()`` causing a TypeError exception when ``$this->cachePage();`` is called with a null argument.

Fixed by instantiating a Cache config object in ``display404errors()`` and passing it to ``gatherOutput()``
  • Loading branch information
dafriend committed Nov 15, 2019
1 parent 9966498 commit 0ac089c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion system/CodeIgniter.php
Original file line number Diff line number Diff line change
Expand Up @@ -883,7 +883,8 @@ protected function display404errors(PageNotFoundException $e)
$this->runController($controller);
}

$this->gatherOutput();
$cacheConfig = new Cache();
$this->gatherOutput($cacheConfig);
$this->sendResponse();

return;
Expand Down

0 comments on commit 0ac089c

Please sign in to comment.