'Gets the IP address of the request'

def get_request_ip_address(self, request):

    ip_address = get_ip(request)
    if (ip_address is not None):
        return ip_address
    else:
        return ''
