Skip to content

Commit 9b6b6da

Browse files
committed
Notify listeners of changes when updating predicate and sort descriptors
1 parent 54716d9 commit 9b6b6da

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Modules/Sources/Yosemite/Tools/ResultsController.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,13 +234,15 @@ public class GenericResultsController<T: ResultsControllerMutableType, Output> {
234234
private func refreshFetchedObjects(predicate: NSPredicate?) {
235235
controller.fetchRequest.predicate = predicate
236236
try? controller.performFetch()
237+
onDidChangeContent?()
237238
}
238239

239240
/// Refreshes all of the Fetched Objects, so that the new sort descriptors are applied.
240241
///
241242
private func refreshFetchedObjects(sortDescriptors: [NSSortDescriptor]?) {
242243
controller.fetchRequest.sortDescriptors = sortDescriptors
243244
try? controller.performFetch()
245+
onDidChangeContent?()
244246
}
245247

246248
/// Initializes the FetchedResultsController

0 commit comments

Comments
 (0)