fix: behavior

This commit is contained in:
Prateek Sunal
2025-02-13 12:46:43 +05:30
parent b68b1a97b5
commit ac9f4e3181

View File

@@ -589,9 +589,9 @@ class PreviewVideoStore {
final allFiles = files
.where((file) => previewIds?[file.uploadedFileID] == null)
.sorted((a, b) {
// put higher duration videos first
final first = a.duration == null || a.duration! >= 20 * 60 * 60 ? 1 : 0;
final second = b.duration == null || b.duration! >= 20 * 60 * 60 ? 1 : 0;
// put higher duration videos last
final first = a.duration == null || a.duration! >= 10 * 60 * 60 ? 1 : 0;
final second = b.duration == null || b.duration! >= 10 * 60 * 60 ? 1 : 0;
return first.compareTo(second);
}).toList();