setup teiserver to send email, but with an invalid TEI_SMTP_HOSTNAME
attempt to register a new account
sending the email will fail and teiserver logs:
[error] Error sending new user email - <THE-EMAIL> - {:network_failure, '127.0.0.1', {:error, :econnrefused}}
Observed behaviour:
There is one row in account_codes for the newly created account.
Expected behaviour:
no code in the table account_codes should be present for the account just created. Teiserver should rollback/delete it.
To reproduce:
[error] Error sending new user email - <THE-EMAIL> - {:network_failure, '127.0.0.1', {:error, :econnrefused}}
Observed behaviour:
There is one row in
account_codes
for the newly created account.Expected behaviour:
no code in the table
account_codes
should be present for the account just created. Teiserver should rollback/delete it.This is a follow up from: https://github.com/beyond-all-reason/teiserver/issues/289 which only handled password reset.