mirror of https://github.com/zulip/zulip.git
Don't let CUSTOMER4 users invite new users to the realm.
As requested by the facilitators: only they should be able to invite new people. (imported from commit 636e332759b9ad56a8d45115d92326a929472c14)
This commit is contained in:
parent
8d40864c8b
commit
088984b31a
|
@ -570,6 +570,12 @@ def home(request):
|
|||
except ValidationError:
|
||||
show_invites = settings.ALLOW_REGISTER
|
||||
|
||||
# For the CUSTOMER4 student realm, only let instructors (who have
|
||||
# @customer4.invalid addresses) invite new users.
|
||||
if ((user_profile.realm.domain == "users.customer4.invalid") and
|
||||
(not user_profile.email.lower().endswith("@customer4.invalid"))):
|
||||
show_invites = False
|
||||
|
||||
return render_to_response('zephyr/index.html',
|
||||
{'user_profile': user_profile,
|
||||
'page_params' : page_params,
|
||||
|
|
Loading…
Reference in New Issue