(htmx): Uso de Context::default() por ::new(None)

This commit is contained in:
Manuel Cillero 2026-07-28 19:09:44 +02:00
parent c91b1cd35c
commit 1a3a295f18
2 changed files with 2 additions and 2 deletions

View file

@ -4,7 +4,7 @@ use pagetop_htmx::prelude::*;
// Forces an effective language different from the default negotiated one (en-US, with no `?lang` in
// the request), so that `Context::route()` decides to propagate `?lang=...` in local routes.
fn cx_with_lang(lang: &str) -> Context {
Context::new(None).with_langid(&Locale::resolve(lang))
Context::default().with_langid(&Locale::resolve(lang))
}
fn header<'a>(response: &'a web::Response, name: &str) -> Option<&'a str> {