Closed natronic closed 2 years ago
Can you give some more context here? There’s no requirement to call this method at any specific point from Pundits point of view.
Can you give some more context here? There’s no requirement to call this method at any specific point from Pundits point of view.
His point that is confusing to a rails new comer where to place the code. His suggestion shows it is to be called from a controller action. It is not a macro method and wouldn't make sense outside of the request/response cycle.
Thanks! We've written the documentation in a similar way for the other code examples, so this makes it consistent if nothing else 🎉
Great job thanks Burgestrand, OSS is hard thanks for the hard work ❤️
Make it clear that authorize controller code has to be placed at the top of controller method(s). Otherwise page will throw errors from any instance variables, etc. that get evaluated before authorization occurs.