@@ -8,11 +8,6 @@ from board.models import Post, Board
|
|||||||
__all__ = ("BoardView", "PostView")
|
__all__ = ("BoardView", "PostView")
|
||||||
|
|
||||||
|
|
||||||
# TODO bump order calculation. this is kind of expensive and should *really*
|
|
||||||
# only be run every few seconds rather than every post.
|
|
||||||
# This is a scale problem and not a high priority.
|
|
||||||
|
|
||||||
|
|
||||||
def get_client_ip(request):
|
def get_client_ip(request):
|
||||||
"Get the IP address of a client-side request. Shamelessly copy/pasted from StackOverflow."
|
"Get the IP address of a client-side request. Shamelessly copy/pasted from StackOverflow."
|
||||||
x_forwarded_for = request.META.get("HTTP_X_FORWARDED_FOR")
|
x_forwarded_for = request.META.get("HTTP_X_FORWARDED_FOR")
|
||||||
|
|||||||
Reference in New Issue
Block a user