jeremykendall / slim-auth

Authorization and authentication for the Slim Framework using ZF2 Authentication and Acl components
MIT License
244 stars 38 forks source link

determineRouteBeforeAppMiddleware #37

Closed urshofer closed 8 years ago

urshofer commented 8 years ago

I'd like just to note that for slim 3.x, the parameter determineRouteBeforeAppMiddlewareneed to be set to trueduring startup, otherwise the auth middleware cannot determine the current route. It should be stated in the docs.

Thanks for your great work! Urs

jeremykendall commented 8 years ago

Excellent point! Thanks!

pip8786 commented 8 years ago

For anyone else checking this, this is how you initialize it: $container = new \Slim\Container(['settings'=>['determineRouteBeforeAppMiddleware'=>true]]);

jeremykendall commented 8 years ago

Fixed in e5383b7, merged into the 3.x branch and released in 2.0.0-alpha+005.

Thanks for opening the issue. Sorry I didn't document this requirement at all :-(