@@ -263,8 +263,10 @@
- (void)reloadDatasource
{
// test
- if (appDelegate.activeAccount.length == 0 || self.view.window == nil)
+ if (appDelegate.activeAccount.length == 0 || self.view.window == nil) {
return;
+ }
+
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
NSArray *recordsTableMetadata = [[NCManageDatabase sharedInstance] getMetadatasWithPredicate:[NSPredicate predicateWithFormat:@"(session CONTAINS 'upload') OR (session CONTAINS 'download')"] page:1 limit:100 sorted:@"sessionTaskIdentifier" ascending:NO];