fix: percent-encode page URLs built from file paths
A file named Müsli.html was indexed with the URL /Müsli.html, which only resolves if the host happens to serve the same byte sequence the index was built from. Encode the URL that build_url derives from the file path using the URL spec's path percent-encode set, leaving / and % alone so path separators and already-encoded filenames are unaffected. URLs supplied by the caller (data-pagefind-meta="url:...", addCustomRecord) do not go through build_url and are untouched. Fixes #619
This commit is contained in:
1 parent
3d8f53f964
commit
128a5c945a
3 files changed
+41
-1
No files matched your search
@@ -90,6 +90,7 @@ actix-web = { version = "4", optional = true }
|
||||
actix-files = { version = "0.7", optional = true }
|
||||
lexical-core = "1.0.0"
|
||||
path-slash = "0.2"
|
||||
percent-encoding = "2"
|
||||
rayon = "1.10"
|
||||
rust-patch = "0.1.3"
|
||||
typed-builder = "0.23.2"
|
||||
|
||||
Reference in new issue
Block a user