Skip to content

[BUG] Wrong endpoint is chosen when having wildcard routes in same level #346

@burbas

Description

@burbas

Describe the bug
Following example won't work:

routes => [
  {":wildcard_path", fun my_controller:function/1, #{methods => [post]},
  {"static_path", fun my_other_controller:function/1, #{methods => [get]}
]

This will give you a 405 when trying to request a GET request to the static_path-endpoint. Even though the pathing is not deterministic - the combination is.

If this is a complex bug

Somewhat complex.

Expected behavior
Would be good if the above example would work as expected - returning what the controller now returns.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions