contrast added
This commit is contained in:
@@ -93,12 +93,13 @@ pub struct CalendarPage {
|
||||
pub rows: Vec<Row>,
|
||||
}
|
||||
|
||||
/// Resolves the UI language from the `lang` cookie (`sk` or `en`, default `en`).
|
||||
/// Resolves the UI language from the `lang` cookie. Slovak is the default;
|
||||
/// English applies only when the cookie explicitly asks for it.
|
||||
#[must_use]
|
||||
pub fn current_lang(jar: &CookieJar) -> String {
|
||||
match jar.get("lang").map(|c| c.value().to_string()) {
|
||||
Some(ref l) if l == "sk" => "sk".to_string(),
|
||||
_ => "en".to_string(),
|
||||
Some(ref l) if l == "en" => "en".to_string(),
|
||||
_ => "sk".to_string(),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user