Skip to content

Commit eec52f0

Browse files
committed
null safety
1 parent be817d7 commit eec52f0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/src/rpc/dial.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ Future _logConnectionStats(Stopwatch webrtcDialSW, RTCPeerConnection peerConnect
234234
if (stat.type == 'candidate-pair' && stat.values['nominated']) {
235235
// Use 'lastPacketSentTimestamp' on candidate pair to estimate when the
236236
// pair was nominated.
237-
final double lpst = stat.values['lastPacketSentTimestamp'] as double;
237+
final double lpst = stat.values['lastPacketSentTimestamp'] ?? 0;
238238
final DateTime nominatedTime = DateTime.fromMillisecondsSinceEpoch(lpst.toInt());
239239

240240
final lcid = stat.values['localCandidateId'];

0 commit comments

Comments
 (0)