SonataUser - Custom Voter with Role Security

北战南征 提交于 2019-12-02 04:16:46

After hours of searching, I noticed that the object received is always NULL (get_class(NULL) returns the current class).

After days of seeking, It turns out that, as opposed to the ACL handler, the default implementation of the Role handler doesn't pass the current object to isGranted()

I had then to extend it.

See a nice monologue in my github issue for more detail.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!