Browse Source

Fix #514

pull/516/head
spikecodes 3 months ago
parent
commit
f5cd48b07f
No known key found for this signature in database GPG Key ID: 4CECFF9B463BCB
  1. 4
      src/server.rs

4
src/server.rs

@ -158,8 +158,8 @@ impl Server {
Ok::<_, String>(service_fn(move |req: Request<Body>| {
let headers = default_headers.clone();
// Remove double slashes
let mut path = req.uri().path().replace("//", "/");
// Remove double slashes and decode encoded slashes
let mut path = req.uri().path().replace("//", "/").replace("%2F","/");
// Remove trailing slashes
if path != "/" && path.ends_with('/') {

Loading…
Cancel
Save