mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
Adding ip address to blocked windows devices.
This commit is contained in:
parent
7be08e15e6
commit
fd766ad544
1 changed files with 2 additions and 1 deletions
|
@ -27,7 +27,8 @@ def login(request):
|
||||||
|
|
||||||
if not user_agent or user_agent.lower() in ['nativehost']:
|
if not user_agent or user_agent.lower() in ['nativehost']:
|
||||||
errors = dict(user_agent="You must set a user agent to login.")
|
errors = dict(user_agent="You must set a user agent to login.")
|
||||||
logging.user(request, "~FG~BB~SK~FRBlocked ~FGAPI Login~SN~FW: %s" % (user_agent))
|
ip = request.META.get('HTTP_X_REAL_IP', None) or request.META['REMOTE_ADDR']
|
||||||
|
logging.user(request, "~FG~BB~SK~FRBlocked ~FGAPI Login~SN~FW: %s / %s" % (user_agent, ip))
|
||||||
elif request.method == "POST":
|
elif request.method == "POST":
|
||||||
form = LoginForm(data=request.POST)
|
form = LoginForm(data=request.POST)
|
||||||
if form.errors:
|
if form.errors:
|
||||||
|
|
Loading…
Add table
Reference in a new issue