Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
The difference between Banken and Pundit
In Pundit, to make a Policy class per Model and make the method which corresponds to Action in Controller in a Policy class, the restrictions as 1 to 1 to 1 are born tacitly in Model, Policy, Controller to use Pundit. Basically, it's ArticlesController to handle Article Model, so ArticlePolicy is needed. In this case, Model, Policy, Controller, there are no problems with 1 to 1 to 1. But, Pundit isn't supporting the case when I need more than one Policy to a Model. (For example when both handle the same User Model by Admin::UsersController and UsersController)
In this case, developer has to settle this problem by himself, and it'll come off how to use original Pundit. Therefore there are various problems that upgrade of Pundit and developer's confusion besides you.
Banken doesn't depend on Model, keeping API like Pundit, and a Loyalty class (class of the same role as Policy in Pundit) is made per Controller, so even if an application becomes complicated and a relation of Model and Controller becomes complicated, it's possible to continue the how to use the Banken origin.
(The Scopes of Pundit doesn't exist in Banken. But I'm thinking it's little no problem even if the method which functions equally exists in Model.)