Permalink
Browse files

There's no .code in URLError

  • Loading branch information...
1 parent 206b5e2 commit e6712a52c17fb3dd1516ee6482dfe84f147225d8 @starenka committed Apr 23, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 mailsnake/mailsnake.py
View
@@ -43,7 +43,7 @@ def call(self, method, params=None):
try:
response = urllib2.urlopen(request)
except urllib2.URLError, e:
- raise NetworkTimeoutException(e.code)
+ raise NetworkTimeoutException(str(e.reason))
except urllib2.HTTPError, e:
raise HTTPRequestException(e.code)

0 comments on commit e6712a5

Please sign in to comment.