-
Notifications
You must be signed in to change notification settings - Fork 373
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Routes with paramters #66
Comments
You should take a look at this issue: #38 |
Thank you, but I've already read this and implemented my own method to replace ids with param1, param2 etc. but it does not solve my problem since in my case the following route: "/resource/:id/subResource/:otherId" could map down to "/resource/aStringID/subResource/123-456-789". I think what I need is a way to get the original route and compare it my self the req.url while omitting any ":x". What do you think? |
Some kind of a solution: What do you think? Am I missing something? |
@LeonLiber if you are using memory-backend, you might consider https://github.com/futurechan/node_acl-mem-regexp It does use regexes, but it's not much different than what you'd already be writing. An example is provided. |
Hi,
I can't seem to understand how to work with express routes with parameters..
Basically what I'm trying to do is to make the following code to grant access to the resource while now it blocks it:
I would expect the resource 'blogs/123' to be mapped to 'blogs/:blogId' but it looks like it does string comparison only, ignoring the fact that ':blogId' could be any number.
I hope I clearly explained my self :)
Thanks
The text was updated successfully, but these errors were encountered: