pub fn verify_password(password: &str) -> Result<(), CaptivePortalError> {
    if password.len() < 8 {
        Err(CaptivePortalError::InvalidSharedKey(format!(
            "Password length should be at least 8 characters: {} len",
            password.len()
        )))
    } else if password.len() > 32 {
        Err(CaptivePortalError::InvalidSharedKey(format!(
            "Password length should not exceed 64: {} len",
            password.len()
        )))
    } else {
        Ok(())
    }
}
/// A wifi password must be between 8 and 32 characters
A wifi password must be between 8 and 32 characters
A wifi password must be between 8 and 32 characters
pub fn verify_password(password: &str) -> Result<(), CaptivePortalError> {
    if password.len() < 8 {
        Err(CaptivePortalError::InvalidSharedKey(format!(
            "Password length should be at least 8 characters: {} len",
            password.len()
        )))
    } else if password.len() > 32 {
        Err(CaptivePortalError::InvalidSharedKey(format!(
            "Password length should not exceed 64: {} len",
            password.len()
        )))
    } else {
        Ok(())
    }
}
pub fn verify_password ( password : & str ) -> Result < ( ) , CaptivePortalError > { if password . len ( ) < 8 { Err ( CaptivePortalError :: InvalidSharedKey ( format ! ( " " password len ( ) ) ) ) } else if password . len ( ) > 32 { Err ( CaptivePortalError :: InvalidSharedKey ( format ! ( " " password len ( ) ) ) ) } else { Ok ( ( ) ) } }
A wifi password must be between 8 and 32 characters
A wifi password must be between 8 and 32 characters
password
&str
password
&str