Skip to main content

resolve_token

Function resolve_token 

Source
pub fn resolve_token(flag: Option<&str>) -> Result<String, AppError>
Expand description

Resolve the shared token from an explicit flag or the TOKEN_ENV env var.

ยงErrors

Returns AppError::validation when no non-empty token is available.