You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to get /admin/entity/s0M3-iD/details the router would incorrectly case that to /admin/entity/s0m3-id/details which then fails to get the entity from the server due to case sensitive ids being used in the database.
By looking at the source code, it seems that this function could be the root cause. In a nested route context, the first part of the pathname could indeed be the named param.
From a naive perspective it seems unnecessary that a router library would make assumptions on the URL casing in any context, and just removing that .toLowerCase makes sense conceptually. Other approach could be to understand if this is a nested route and catch that separately.
Any thoughts on this? Happy to see this through into a PR once we land on a solution path.
Thanks :)
The text was updated successfully, but these errors were encountered:
👋 Hello @jorgegorka
We found an issue which seems to be affecting only nested routes whose first path is a named param. For example
When trying to get
/admin/entity/s0M3-iD/details
the router would incorrectly case that to/admin/entity/s0m3-id/details
which then fails to get the entity from the server due to case sensitive ids being used in the database.By looking at the source code, it seems that this function could be the root cause. In a nested route context, the first part of the pathname could indeed be the named param.
From a naive perspective it seems unnecessary that a router library would make assumptions on the URL casing in any context, and just removing that
.toLowerCase
makes sense conceptually. Other approach could be to understand if this is a nested route and catch that separately.Any thoughts on this? Happy to see this through into a PR once we land on a solution path.
Thanks :)
The text was updated successfully, but these errors were encountered: