0
0
Fork 0
mirror of https://github.com/dani-garcia/vaultwarden synced 2024-12-13 17:22:58 +01:00

Don't error if admin token is empty but disabled

This commit is contained in:
Daniel García 2020-01-30 22:10:50 +01:00
parent 3d1ee9ef62
commit 480ba933fa
No known key found for this signature in database
GPG key ID: FC8A7D14C3CD543A

View file

@ -405,7 +405,7 @@ fn validate_config(cfg: &ConfigItems) -> Result<(), Error> {
}
if let Some(ref token) = cfg.admin_token {
if token.trim().is_empty() {
if token.trim().is_empty() && !cfg.disable_admin_token {
err!("`ADMIN_TOKEN` is enabled but has an empty value. To enable the admin page without token, use `DISABLE_ADMIN_TOKEN`")
}
}