Skip to content

fix(server/resources): decode percent-encoded resource name from URI fragment#4002

Closed
lucienlmy wants to merge 1 commit into
citizenfx:masterfrom
lucienlmy:patch-3
Closed

fix(server/resources): decode percent-encoded resource name from URI fragment#4002
lucienlmy wants to merge 1 commit into
citizenfx:masterfrom
lucienlmy:patch-3

Conversation

@lucienlmy
Copy link
Copy Markdown

@lucienlmy lucienlmy commented May 22, 2026

Resource names from URI fragments were not decoded back from
percent-encoding, causing non-ASCII resource names (e.g. Chinese)
to be registered as encoded strings like "%E8%B7%91%E9%85%B7".

This resulted in:

  • ensure <resource> unable to find resources with non-ASCII names
  • Garbled resource names in console warnings/errors

The path component already calls skyr::percent_decode(), but the
fragment (used as the resource name) was missing the same treatment.
Adding it makes the encode/decode cycle symmetric.

Resource names from URI fragments were not decoded back from
percent-encoding, causing non-ASCII resource names (e.g. Chinese)
to be registered as encoded strings like "%E8%B7%91%E9%85%B7".

This resulted in:
- `ensure <resource>` unable to find resources with non-ASCII names
- Garbled resource names in console warnings/errors

The path component already calls `skyr::percent_decode()`, but the
fragment (used as the resource name) was missing the same treatment.
Adding it makes the encode/decode cycle symmetric.
@github-actions github-actions Bot added the invalid Requires changes before it's considered valid and can be (re)triaged label May 22, 2026
@lucienlmy lucienlmy changed the title Fix resource name percent-decoding in ServerResourceMounter fix(server/resources): decode percent-encoded resource name from URI fragment May 22, 2026
@lucienlmy lucienlmy closed this May 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

invalid Requires changes before it's considered valid and can be (re)triaged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant