You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Following the documentation, It seems that register is not an attribute of authority:
import authority
from authority import permissions
from django.contrib.flatpages.models import FlatPage
class FlatpagePermission(permissions.BasePermission):
label = 'flatpage_permission'
authority.register(FlatPage, FlatpagePermission)
This gave me the error: AttributeError: module 'authority' has no attribute 'register'
I then discovered that there is this, which seems to not throw the error but I'm not sure if this will do the same thing: authority.utils.register(FlatPage, FlatPagePermission)
Is this correct, or did I not do something correctly?
The text was updated successfully, but these errors were encountered:
Following the documentation, It seems that register is not an attribute of authority:
This gave me the error:
AttributeError: module 'authority' has no attribute 'register'
I then discovered that there is this, which seems to not throw the error but I'm not sure if this will do the same thing:
authority.utils.register(FlatPage, FlatPagePermission)
Is this correct, or did I not do something correctly?
The text was updated successfully, but these errors were encountered: