Skip to content

Commit f89fc24

Browse files
committed
Fix code
1 parent 613290a commit f89fc24

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

readthedocs/analytics/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def get_client_ip(request):
3232
client_ip = x_forwarded_for.split(',')[0].strip()
3333

3434
# Removing the port number (if present)
35-
client_ip = x_forwarded_for.rsplit(':')[0]
35+
client_ip = client_ip.rsplit(':')[0]
3636
else:
3737
client_ip = request.META.get('REMOTE_ADDR', None)
3838

0 commit comments

Comments
 (0)