Skip to content

Commit

Permalink
Fixed iOS network error
Browse files Browse the repository at this point in the history
  • Loading branch information
Decoder07 committed Apr 19, 2024
1 parent e982224 commit 1454865
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,6 @@ class HLSPlayerStore extends ChangeNotifier
@override
void onPlaybackFailure({required String? error}) {
log("Playback failure $error");
isPlayerFailed = true;
notifyListeners();
}

@override
Expand All @@ -169,6 +167,9 @@ class HLSPlayerStore extends ChangeNotifier
isPlayerFailed = false;
areClosedCaptionsSupported();
}
if (playerPlaybackState == HMSHLSPlaybackState.FAILED) {
isPlayerFailed = true;
}
notifyListeners();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ class _HLSStreamTimerState extends State<HLSStreamTimer> {
_minutes %= 60;
}

///We only show seconds if hours and minutes are 0
///only minutes if hours are 0
///only hours if hours are greater than 0
return "Started${_hours > 0 ? " ${_hours.toString()}h" : ""} ${_hours < 1 && _minutes > 0 ? "${_minutes.toString()}m" : ""} ${_hours < 1 && _minutes < 1 ? "${_seconds.toString()}s " : ""}ago";
}

Expand Down

0 comments on commit 1454865

Please sign in to comment.