We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c40247e commit 1d1600bCopy full SHA for 1d1600b
1 file changed
packages/audioplayers_web/lib/wrapped_player.dart
@@ -52,7 +52,7 @@ class WrappedPlayer {
52
}
53
Duration toDuration(num jsNum) => Duration(
54
milliseconds:
55
- (1000 * (jsNum.toString() == 'NaN' ? 0 : jsNum)).round(),
+ (1000 * (jsNum.isNaN || jsNum.isInfinite ? 0 : jsNum)).round(),
56
);
57
58
final p = player = AudioElement(currentUrl);
0 commit comments