diff options
Diffstat (limited to 'askbot/models/user.py')
-rw-r--r-- | askbot/models/user.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/askbot/models/user.py b/askbot/models/user.py index e4077ea5..14c1d189 100644 --- a/askbot/models/user.py +++ b/askbot/models/user.py @@ -11,6 +11,7 @@ from django.forms import EmailField, URLField from django.utils.translation import ugettext as _ from django.utils.html import strip_tags from askbot import const +from askbot.conf import settings as askbot_settings from askbot.utils import functions from askbot.models.tag import Tag from askbot.forms import DomainNameField @@ -380,6 +381,10 @@ class GroupProfile(models.Model): if user.is_anonymous(): return False + #a special case - automatic global group cannot be joined or left + if self.group_tag.name == askbot_settings.GLOBAL_GROUP_NAME: + return False + if self.is_open: return True |