Skip to content

Commit

Permalink
Merge pull request codeigniter4#9314 from paulbalandan/rename-control…
Browse files Browse the repository at this point in the history
…ler-to-Controller

refactor: rename `controller` to `Controller`
  • Loading branch information
samsonasik authored Dec 11, 2024
2 parents f5200b5 + 562ddf2 commit 0b0126c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
6 changes: 0 additions & 6 deletions phpstan-baseline.php
Original file line number Diff line number Diff line change
Expand Up @@ -16549,12 +16549,6 @@
'count' => 2,
'path' => __DIR__ . '/tests/system/Router/RouteCollectionTest.php',
];
$ignoreErrors[] = [
// identifier: class.nameCase
'message' => '#^Class CodeIgniter\\\\Controller referenced with incorrect case\\: CodeIgniter\\\\controller\\.$#',
'count' => 2,
'path' => __DIR__ . '/tests/system/Router/RouteCollectionTest.php',
];
$ignoreErrors[] = [
// identifier: missingType.return
'message' => '#^Method CodeIgniter\\\\Router\\\\RouteCollectionTest\\:\\:getCollector\\(\\) has no return type specified\\.$#',
Expand Down
6 changes: 3 additions & 3 deletions tests/system/Router/RouteCollectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
namespace CodeIgniter\Router;

use App\Controllers\Product;
use CodeIgniter\controller;
use CodeIgniter\Controller;
use CodeIgniter\Exceptions\PageNotFoundException;
use CodeIgniter\HTTP\Method;
use CodeIgniter\Test\CIUnitTestCase;
Expand Down Expand Up @@ -243,10 +243,10 @@ public function testAddRecognizesCustomNamespaces(): void
$routes = $this->getCollector();
$routes->setDefaultNamespace('\CodeIgniter');

$routes->add('home', 'controller');
$routes->add('home', 'Controller');

$expects = [
'home' => '\\' . controller::class,
'home' => '\\' . Controller::class,
];

$routes = $routes->getRoutes();
Expand Down

0 comments on commit 0b0126c

Please sign in to comment.