logging confirmation links for debug purposes

multi-deployment
b3yond 2018-09-09 14:57:40 +02:00
parent 185014a452
commit 40c834020a
2 changed files with 7 additions and 7 deletions

View File

@ -39,13 +39,13 @@ def register_post():
return dict(error='Email address already in use.')
# send confirmation mail
try:
print(url('confirm/' + city + '/%s' % db.user_token(email, password))) # only for local testing
link = url('confirm/' + city + '/%s' % db.user_token(email, password))
print(link) # only for local testing
logger.info('confirmation link to ' + email + ": " + link)
sendmail(
email,
"Confirm your account",
"Complete your registration here: %s" % (
url('confirm/' + city + '/%s' % db.user_token(email, password))
)
"Complete your registration here: %s" % (link)
)
return dict(info='Confirmation mail sent.')
except Exception: