Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
AE UTBM
Sith
Commits
e7f7c575
Commit
e7f7c575
authored
Jun 06, 2017
by
Skia
🤘
Browse files
Fix AnonymousUser
Signed-off-by:
Skia
<
skia@libskia.so
>
parent
cef22306
Pipeline
#1018
passed with stage
in 4 minutes and 39 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
core/models.py
View file @
e7f7c575
...
...
@@ -28,7 +28,7 @@ from django.contrib.auth.models import AbstractBaseUser, PermissionsMixin, UserM
from
django.utils.translation
import
ugettext_lazy
as
_
from
django.utils
import
timezone
from
django.core
import
validators
from
django.core.exceptions
import
ValidationError
from
django.core.exceptions
import
ValidationError
,
PermissionDenied
from
django.core.urlresolvers
import
reverse
from
django.conf
import
settings
from
django.db
import
transaction
...
...
@@ -495,31 +495,35 @@ class AnonymousUser(AuthAnonymousUser):
@
property
def
was_subscribed
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
subscribed
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
is_root
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
is_board_member
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
is_launderette_manager
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
is_banned_alcohol
(
self
):
r
eturn
False
r
aise
PermissionDenied
@
property
def
is_banned_conuter
(
self
):
return
False
def
is_banned_counter
(
self
):
raise
PermissionDenied
@
property
def
forum_infos
(
self
):
raise
PermissionDenied
def
is_in_group
(
self
,
group_name
):
"""
...
...
Skia
🤘
@skia
Mentioned in commit
b06f270e
·
Jun 12, 2017
Mentioned in commit
b06f270e
Mentioned in commit b06f270ea5b3b303fb4c1dc80b63249ccceb251d
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment