File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4444 * It is called by Config\Routes, and has the $routes RouteCollection
4545 * already loaded up and ready for us to use.
4646 */
47+ // Prevent access to BaseController
48+ $ routes ->add ('basecontroller(:any) ' , function ()
49+ {
50+ throw \CodeIgniter \Exceptions \PageNotFoundException::forPageNotFound ();
51+ });
52+
4753// Migrations
4854$ routes ->cli ('migrations/(:segment)/(:segment) ' , '\CodeIgniter\Commands\MigrationsCommand::$1/$2 ' );
4955$ routes ->cli ('migrations/(:segment) ' , '\CodeIgniter\Commands\MigrationsCommand::$1 ' );
5056$ routes ->cli ('migrations ' , '\CodeIgniter\Commands\MigrationsCommand::index ' );
5157
5258// CLI Catchall - uses a _remap to call Commands
5359$ routes ->cli ('ci(:any) ' , '\CodeIgniter\CLI\CommandRunner::index/$1 ' );
54-
55- // Prevent access to BaseController
56- $ routes ->add ('basecontroller(:any) ' , function ()
57- {
58- throw \CodeIgniter \Exceptions \PageNotFoundException::forPageNotFound ();
59- });
You can’t perform that action at this time.
0 commit comments