simple-php-router icon indicating copy to clipboard operation
simple-php-router copied to clipboard

Allow Middleware parameters

Open michaelthedev opened this issue 1 year ago • 1 comments

Allows usage of comma separated values as middleware parameters

Router::post('/purchase', [CableTvController::class, 'purchase'])
  ->addMiddleware(PinVerified::class.',value_1,value_2');

OR

Router::post('/purchase', [CableTvController::class, 'purchase'])
  ->addMiddleware('App\Middlewares\TestMiddleware,value_1,value_2');

michaelthedev avatar Jun 26 '24 09:06 michaelthedev

Not sure which branch i should choose. But i selected v5-development

michaelthedev avatar Jun 26 '24 09:06 michaelthedev