mirror of
https://github.com/bblaz/num2words.git
synced 2026-11-12 20:35:27 +00:00
Add AttributeError to to_cardinal_float
Signed-off-by: William José Moreno Reyes <williamjmorenor@gmail.com>
This commit is contained in:
1 parent
4f116228b5
commit
601e8cee84
1 file changed
+1
-1
+1
-1
@@ -139,7 +139,7 @@ class Num2Word_Base(object):
|
||||
def to_cardinal_float(self, value):
|
||||
try:
|
||||
float(value) == value
|
||||
except (ValueError, TypeError, AssertionError):
|
||||
except (ValueError, TypeError, AssertionError, AttributeError):
|
||||
raise TypeError(self.errmsg_nonnum % value)
|
||||
|
||||
pre, post = self.float2tuple(float(value))
|
||||
|
||||
Reference in new issue
Block a user