Skip to content
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

add a flag #2

Open
eivindfjeldstad opened this issue Mar 16, 2014 · 2 comments
Open

add a flag #2

eivindfjeldstad opened this issue Mar 16, 2014 · 2 comments

Comments

@eivindfjeldstad
Copy link
Member

would be useful to have a flag to indicate that a path has been rewritten. maybe ctx.rewrite = true or similar. would you accept a PR?

@tj
Copy link
Member

tj commented Mar 17, 2014

we could have something like ctx.request.original.path == ctx.path (with a less verbose name hopefully haha), that way you wouldn't have to "reset" ctx.rewrite if it happens to get changed back to the original again, not sure. I don't think there's a huge huge use-case for it, logging is usually done in the most upstream middleware etc. What's your use-case?

@eivindfjeldstad
Copy link
Member Author

hmm, yeah. it gets a little weird when you have mounted apps, maybe with their own logging etc. that's my use-case at least. having a way to get at the original path would work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants