http-rs / http-rs/route-recognizer

Query string ends up in the last matching parameter's value

Open
#30 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
101
Forks
35
PR merge metrics
No merged PRs in 30d

Description

When parsing a URL if the path contains a query string at the end e.g. ``/api/something?a=b&c=d`` given a rule of ``/api/:what`` the value of the query string ends up being appended to parameter - in this example ``match.params["what"] == "something?a=b&c=d"``.

It would make sense to introduce the concept of the query string at least and remove it from the last match entry when producing the parameter map.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.