diff --git a/server/src/account.rs b/server/src/account.rs index 30a37c53..5aa655d3 100644 --- a/server/src/account.rs +++ b/server/src/account.rs @@ -65,6 +65,10 @@ pub fn account_create(params: AccountCreateParams, tx: &mut Transaction) -> Resu return Err(err_msg("password must be at least 12 characters")); } + if params.name.len() == 0 { + return Err(err_msg("account name not supplied")); + } + let rounds = 8; let password = hash(¶ms.password, rounds)?;