getLoginName static method
Retrieves the user name from the given email and
the discovered serverConfig.
Defaults to the email when the serverConfig does not contain any rules.
Implementation
static String getLoginName(String email, ServerConfig serverConfig) =>
serverConfig.getUserName(email) ?? email;