refactor+fix various issues with regs/logins and admin user commands
Signed-off-by: June Clementine Strawberry <june@3.dog>
This commit is contained in:
parent
00cc23b649
commit
af714d5778
11 changed files with 309 additions and 220 deletions
|
@ -126,6 +126,14 @@ pub fn check(config: &Config) -> Result {
|
|||
));
|
||||
}
|
||||
|
||||
if config.emergency_password == Some(String::new()) {
|
||||
return Err!(Config(
|
||||
"emergency_password",
|
||||
"Emergency password was set to an empty string, this is not valid. Unset \
|
||||
emergency_password to disable it or set it to a real password."
|
||||
));
|
||||
}
|
||||
|
||||
// check if the user specified a registration token as `""`
|
||||
if config.registration_token == Some(String::new()) {
|
||||
return Err!(Config(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue