set remoteId as we need it for thumbnails

Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
This commit is contained in:
tobiasKaminsky 2023-02-02 10:55:06 +01:00
parent 395af69162
commit d68e79d547
No known key found for this signature in database
GPG key ID: 0E00D4D47D0C5AF7
2 changed files with 1 additions and 5 deletions

View file

@ -56,7 +56,7 @@ object OCShareToOCFileConverter {
mimeType = firstShare.mimetype
note = firstShare.note
fileId = firstShare.fileSource
remoteId = "-1" // remoteId is not given from server
remoteId = firstShare.remoteId.toString()
// use first share timestamp as timestamp
firstShareTimestamp = shares.minOf { it.sharedDate * MILLIS_PER_SECOND }
// don't have file length or mod timestamp

View file

@ -99,10 +99,6 @@ open class FileSortOrder(@JvmField var name: String, var isAscending: Boolean) {
}
}
open fun sortSharedFiles(files: MutableList<OCFile>): List<OCFile> {
return files.sortedByDescending { it.firstShareTimestamp }
}
open fun sortCloudFiles(files: MutableList<OCFile>): List<OCFile> {
return sortCloudFilesByFavourite(files)
}