mirror of
https://github.com/neocities/neocities.git
synced 2025-07-20 17:46:05 +02:00
initial contact form for domain registration
This commit is contained in:
parent
f026d9d5fe
commit
47c0e52d93
7 changed files with 1051 additions and 1 deletions
|
@ -823,6 +823,10 @@ class Site < Sequel::Model
|
|||
errors.add :email, 'An email address is required.'
|
||||
end
|
||||
|
||||
if parent? && values[:email] =~ /@neocities.org/
|
||||
errors.add :email, 'Cannot use this email address.'
|
||||
end
|
||||
|
||||
# Check for existing email if new or changing email.
|
||||
if new? || @original_email
|
||||
email_check = self.class.select(:id).filter(email: values[:email])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue