Last active
November 10, 2015 04:03
-
-
Save igroomgrim/152b72762892e26fd47e to your computer and use it in GitHub Desktop.
Sorting realm object with sorted function.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let predicate = NSPredicate(format: "done == %@", NSNumber(bool: true)) | |
let tasks = realm.objects(TDTask).filter(predicate).sorted("created",ascending:false) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment