Function twilight_validate::request::nickname

source ·
pub fn nickname(nickname: impl AsRef<str>) -> Result<(), ValidationError>
Expand description

Ensure that the nickname length is correct.

The length must be at least NICKNAME_LIMIT_MIN and at most NICKNAME_LIMIT_MAX. This is based on this documentation entry.

§Errors

Returns an error of type Nickname if the length is invalid.