fix: duration getting saved for some short videos

This commit is contained in:
omkar 2025-01-11 11:16:11 +05:30
parent f13ff6fc9f
commit 2a7b253f06

View file

@ -66,7 +66,7 @@ class _VideoViewerState extends State<VideoViewer> {
Future<void> saveWatchHistory() async {
final duration = player.state.duration.inSeconds;
if (duration < 30) {
if (duration <= 30) {
_logger.info('Video is too short to track.');
return;
}