mirror of
https://github.com/r4sas/py-i2phosts
synced 2025-08-27 14:12:10 +00:00
Fix undefined variable
This commit is contained in:
parent
ca831b2d45
commit
6ac3284396
@ -129,7 +129,7 @@ def subdomain(request):
|
|||||||
resp = opener.open(url, timeout=60)
|
resp = opener.open(url, timeout=60)
|
||||||
except urllib2.URLError, e:
|
except urllib2.URLError, e:
|
||||||
if hasattr(e, 'reason'):
|
if hasattr(e, 'reason'):
|
||||||
log.warning('%s: failed to reach server, reason: %s', topdomain, e.reason)
|
log.warning('%s: failed to reach server, reason: %s', request.session['topdomain'], e.reason)
|
||||||
elif hasattr(e, 'code'):
|
elif hasattr(e, 'code'):
|
||||||
log.warning('%s can\'t finish the request, error code: %s',
|
log.warning('%s can\'t finish the request, error code: %s',
|
||||||
request.session['topdomain'], e.code)
|
request.session['topdomain'], e.code)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user