1
0
Fork 0
mirror of https://git.42l.fr/neil/sncf.git synced 2024-04-28 12:12:44 +02:00

fixing cookie regex again

This commit is contained in:
neil 2020-08-22 16:01:23 +02:00
parent 5a6f600806
commit 1c02c142c9

View file

@ -164,7 +164,7 @@ pub async fn forward_register(
// if the user has already generated an admin token, redirect too
if let Some(token) = has_admintoken(&req) {
lazy_static! {
static ref RE: Regex = Regex::new(r#"sncf_admin_token=(?P<token>[0-9A-Za-z_]*)"#).expect("Error while parsing the sncf_admin_token regex");
static ref RE: Regex = Regex::new(r#"sncf_admin_token=(?P<token>[0-9A-Za-z_\-]*)"#).expect("Error while parsing the sncf_admin_token regex");
}
let admin_token = RE.captures(&token)
.ok_or_else(|| {