Skip to content

Commit 61cc2ec

Browse files
Convert from int to double to avoid auto casting which throws an error on Android (#55)
https://stackoverflow.com/questions/58986585/type-int-is-not-a-subtype-of-type-double
1 parent c8a1193 commit 61cc2ec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

firestore/lib/src/model/review.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class Review {
4343
return Review._(
4444
id: snapshot.id,
4545
userId: _snapshot['userId'],
46-
rating: _snapshot['rating'],
46+
rating: _snapshot['rating'].toDouble(),
4747
text: _snapshot['text'],
4848
userName: _snapshot['userName'],
4949
timestamp: _snapshot['timestamp'],

0 commit comments

Comments
 (0)