PEP8 cleanups, specially E501 line too long.

This commit is contained in:
Roberto Rosario
2015-07-22 18:21:37 -04:00
parent c275988c90
commit 4527563d89
118 changed files with 2839 additions and 756 deletions

View File

@@ -23,7 +23,9 @@ class PermissionNamespace(object):
try:
return cls._registry[name]
except KeyError:
raise InvalidNamespace('Invalid namespace name. This is probably an obsolete permission namespace, execute the management command "purge_permissions" and try again.')
raise InvalidNamespace(
'Invalid namespace name. This is probably an obsolete permission namespace, execute the management command "purge_permissions" and try again.'
)
def __init__(self, name, label):
self.name = name
@@ -65,7 +67,9 @@ class Permission(object):
@classmethod
def all(cls):
# Return sorted permisions by namespace.name
return sorted(cls._permissions.values(), key=lambda x: x.namespace.name)
return sorted(
cls._permissions.values(), key=lambda x: x.namespace.name
)
@classmethod
def get(cls, get_dict, proxy_only=False):