1
0
Fork 1
Spiegel von https://github.com/dani-garcia/vaultwarden.git synchronisiert 2024-11-29 06:20:29 +01:00

SIGNUPS_ALLOWED with no whitelist [fixes #830]

This reverts back to `SIGNUPS_ALLOWED` when there is no domain whitelist
set. The functionality was broken in 64d6f72.
Dieser Commit ist enthalten in:
Miro Prasil 2020-01-29 11:32:42 +00:00
Ursprung 632d55265b
Commit c4101162d6

Datei anzeigen

@ -515,7 +515,7 @@ impl Config {
// (it doesn't contain any domains), or if it matches at least // (it doesn't contain any domains), or if it matches at least
// one domain. // one domain.
let whitelist_str = self.signups_domains_whitelist(); let whitelist_str = self.signups_domains_whitelist();
whitelist_str.is_empty() || whitelist_str.split(',').filter(|s| !s.is_empty()).any(|d| d == e[0]) ( whitelist_str.is_empty() && CONFIG.signups_allowed() )|| whitelist_str.split(',').filter(|s| !s.is_empty()).any(|d| d == e[0])
} }
pub fn delete_user_config(&self) -> Result<(), Error> { pub fn delete_user_config(&self) -> Result<(), Error> {