FIX_OPTIONS_ROUTE_ADDED_4_CORS

This commit is contained in:
velz 2025-11-25 15:02:47 +05:30
parent bcbe96ad0d
commit 6aafc8ae91

View File

@ -3,6 +3,13 @@
use CodeIgniter\Router\RouteCollection;
// Allow OPTIONS for all routes
$routes->options('(:any)', function() {
// This will never be called because the CORS filter returns early
// But having this route ensures OPTIONS isn't rejected as 404
});
/**
* @var RouteCollection $routes
*/