bumped the django versions on travis, and added a fix to get_ip()

This commit is contained in:
Ken Cochrane 2015-02-25 10:03:05 -05:00
parent fd4f58a20c
commit ea7a8cde06
2 changed files with 4 additions and 4 deletions

View file

@ -8,8 +8,8 @@ python:
- "pypy"
env:
- DJANGO=Django==1.6.9
- DJANGO=Django==1.7.2
- DJANGO=Django==1.6.10
- DJANGO=Django==1.7.5
services:
- redis-server
@ -28,7 +28,7 @@ script:
matrix:
exclude:
- python: "2.6"
env: DJANGO=Django==1.7.2
env: DJANGO=Django==1.7.5
after_success:
- coveralls --verbose

View file

@ -43,7 +43,7 @@ def get_ip(request):
ip = request.META.get(config.REVERSE_PROXY_HEADER, '')
ip = ip.split(",", 1)[0].strip()
if ip == '':
ip = request.META.get('REMOTE_ADDR', '')
ip = get_ip_address_from_request(request)
else:
ip = get_ip_address_from_request(request)
return ip