Skip to content

Commit

Permalink
chore: Order expired transfers to the end of the list
Browse files Browse the repository at this point in the history
  • Loading branch information
tevincent committed Jan 15, 2025
1 parent 6b54413 commit dc3f6b6
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,11 @@ class TransferController(private val realmProvider: RealmProvider) {
null -> TRUE_PREDICATE
else -> "${TransferDB.transferDirectionPropertyName} == '${transferDirection}'"
}
return realm.query<TransferDB>(directionFilterQuery).sort(TransferDB::createdDateTimestamp.name, Sort.DESCENDING)
return realm
.query<TransferDB>(directionFilterQuery)
.sort(TransferDB::createdDateTimestamp.name, Sort.DESCENDING)
.sort(TransferDB::expiredDateTimestamp.name, Sort.DESCENDING)
.sort(TransferDB::downloadCounterCredit.name, Sort.DESCENDING)
}
}
}

0 comments on commit dc3f6b6

Please sign in to comment.