Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/develop' into 4.5
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Oct 8, 2023
2 parents edfa0b5 + f277814 commit 70c400c
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"phpunit/phpcov": "^8.2",
"phpunit/phpunit": "^9.1",
"predis/predis": "^1.1 || ^2.0",
"rector/rector": "0.18.4",
"rector/rector": "0.18.5",
"vimeo/psalm": "^5.0"
},
"suggest": {
Expand Down
4 changes: 0 additions & 4 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
use Rector\EarlyReturn\Rector\Return_\PreparedValueToEarlyReturnRector;
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
use Rector\Php70\Rector\FuncCall\RandomFunctionRector;
use Rector\Php71\Rector\FuncCall\CountOnNullRector;
use Rector\Php73\Rector\FuncCall\JsonThrowOnErrorRector;
use Rector\PHPUnit\CodeQuality\Rector\Class_\YieldDataProviderRector;
use Rector\PHPUnit\Set\PHPUnitSetList;
Expand Down Expand Up @@ -105,9 +104,6 @@
__DIR__ . '/system/Session/Handlers',
],

// sometime too detail
CountOnNullRector::class,

// use mt_rand instead of random_int on purpose on non-cryptographically random
RandomFunctionRector::class,

Expand Down
3 changes: 1 addition & 2 deletions system/CodeIgniter.php
Original file line number Diff line number Diff line change
Expand Up @@ -971,8 +971,7 @@ protected function display404errors(PageNotFoundException $e)
// Display 404 Errors
$this->response->setStatusCode($e->getCode());

echo $this->outputBufferingEnd();
flush();
$this->outputBufferingEnd();

// Throws new PageNotFoundException and remove exception message on production.
throw PageNotFoundException::forPageNotFound(
Expand Down
2 changes: 1 addition & 1 deletion system/Debug/Toolbar.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public function run(float $startTime, float $totalTime, RequestInterface $reques
$data['isAJAX'] = $request->isAJAX();
$data['startTime'] = $startTime;
$data['totalTime'] = $totalTime * 1000;
$data['totalMemory'] = number_format((memory_get_peak_usage()) / 1024 / 1024, 3);
$data['totalMemory'] = number_format(memory_get_peak_usage() / 1024 / 1024, 3);
$data['segmentDuration'] = $this->roundTo($data['totalTime'] / 7);
$data['segmentCount'] = (int) ceil($data['totalTime'] / $data['segmentDuration']);
$data['CI_VERSION'] = CodeIgniter::CI_VERSION;
Expand Down
3 changes: 3 additions & 0 deletions user_guide_src/source/changelogs/v4.4.2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ Deprecations
Bugs Fixed
**********

- **CodeIgniter:** Fixed a bug that returned "200 OK" response status code when
Page Not Found.

See the repo's
`CHANGELOG.md <https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md>`_
for a complete list of bugs fixed.
4 changes: 2 additions & 2 deletions user_guide_src/source/extending/core_classes/003.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

namespace App\Libraries;

use CodeIgniter\Router\RouteCollection;
use CodeIgniter\Router\RouteCollection as BaseRouteCollection;

class RouteCollection extends RouteCollection
class RouteCollection extends BaseRouteCollection
{
// ...
}

0 comments on commit 70c400c

Please sign in to comment.