mirror of
https://github.com/aljazceru/CTFd.git
synced 2025-12-20 07:14:24 +01:00
Fix creating users, teams from the API (#768)
* Fix creating users, teams from the API, hash password in models vs in schemas, stop caching CSS at the decorator level, fix tests * Fix whitelisted emails and add test * Set proper defaults in accounts config
This commit is contained in:
@@ -153,7 +153,7 @@ def register():
|
||||
if not valid_email:
|
||||
errors.append("Please enter a valid email address")
|
||||
if domain_whitelist:
|
||||
domain_whitelist = domain_whitelist.split(',')
|
||||
domain_whitelist = [d.strip() for d in domain_whitelist.split(',')]
|
||||
if domain not in domain_whitelist:
|
||||
errors.append(
|
||||
"Only email addresses under {domains} may register".format(
|
||||
|
||||
Reference in New Issue
Block a user