all lowercase
All checks were successful
Build Project / test (push) Successful in 3m9s

This commit is contained in:
2025-11-05 19:56:38 +00:00
parent d4dc0cbbf7
commit f0a90a4882

View File

@@ -91,6 +91,8 @@ async fn serve_firmware(
) -> impl Responder {
let (service, product, config, version) = path.into_inner();
let version = version.replace(['.', '_'], "-");
let service = service.to_lowercase();
let config = config.to_lowercase();
let Ok(service) = Services::from_str(&service) else {
return HttpResponse::NotFound().finish();
};
@@ -101,7 +103,7 @@ async fn serve_firmware(
Services::Firmware => PathBuf::from(format!("{product}/firmware_{config}_{version}.bin")),
Services::Filesystem => PathBuf::from(format!("{product}/filesystem_{config}_{version}.bin")),
};
let file_path = fw_root_path.join(&file_path);