Fix issue for returning dynamodb floats. Closes #812.
This commit is contained in:
parent
4eaf5d527e
commit
ba7223f046
1 changed files with 4 additions and 1 deletions
|
|
@ -56,7 +56,10 @@ class DynamoType(object):
|
||||||
@property
|
@property
|
||||||
def cast_value(self):
|
def cast_value(self):
|
||||||
if self.type == 'N':
|
if self.type == 'N':
|
||||||
return int(self.value)
|
try:
|
||||||
|
return int(self.value)
|
||||||
|
except ValueError:
|
||||||
|
return float(self.value)
|
||||||
else:
|
else:
|
||||||
return self.value
|
return self.value
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue