Unifomize license headers
This commit is contained in:
parent
9dc40279fa
commit
8d44182af8
51 changed files with 249 additions and 135 deletions
|
|
@ -1,3 +1,7 @@
|
|||
# This file is part of photo21
|
||||
# Copyright (C) 2022 Amicale des élèves de l'ENS Paris-Saclay
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
from django import forms
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from allauth.account.forms import SignupForm
|
||||
|
|
@ -18,7 +22,9 @@ class CustomSignupForm(SignupForm):
|
|||
Check that the email address ends with a trusted domain.
|
||||
"""
|
||||
email = super().clean_email()
|
||||
if not email.endswith("@crans.org") and not email.endswith("@ens-paris-saclay.fr"):
|
||||
if not email.endswith("@crans.org") and not email.endswith(
|
||||
"@ens-paris-saclay.fr"
|
||||
):
|
||||
raise forms.ValidationError(
|
||||
_("Must end with `@crans.org` or `@ens-paris-saclay.fr`.")
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue