1 2 3 4 5 6 7 8 9 10 11 12 13 14
#[derive(Debug, Default)] pub struct Config { pub base_url: http::Uri, pub token: String, } impl Config { pub fn new(url: http::Uri, token: &str) -> Self { Self { base_url: url, token: token.to_string(), } } }