-
Notifications
You must be signed in to change notification settings - Fork 91
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 middleware for easy usage #36
Comments
@wolph ipware is to return the IP address. Each project knows what needs to be done with the IP. Best practice is to call ipware on the first request and cache it for subsequent use. Then use the IP as it fits the project requirements. |
I don't get what you're trying to say... I'm saying it would be useful to have a middleware integrated into the project. Something similar to this one: https://github.com/allo-/django-xforwardedfor-middleware/blob/master/x_forwarded_for/middleware.py As for caching, that would be a useful thing to integrate into that middleware :) |
@wolph I see ... just a simple thing to make IP available downstream ... cool. |
I'm aware that writing the middleware manually is just a few lines of code but it would be very useful to have a simple middleware available
Within views it's easy enough to simply import the methods but Django still needs patching to have
INTERNAL_IPS
work correctlyThe text was updated successfully, but these errors were encountered: