jooby-project / jooby

The modular web framework for Java and Kotlin
https://jooby.io
Apache License 2.0
1.7k stars 199 forks source link

context path/path map uses incorrect keys on mount #3474

Closed ross-oreto closed 1 month ago

ross-oreto commented 2 months ago

jooby: 3.2.4 JDK 17 Windows 11

When mounting a path with a parameter using mount(), the context map doesn't use the path parameter name and instead uses the param index such as 0, 1 etc.

Expected behavior: The path map would have a key named "id" and the variable id would be non-null Actual behavior: The path map has an integer key 0 which maps to the value and in this example, id is null when searching for string key "id"