(fix) cache sogo_folder_info records and avoid phantom subscriptions (fixes #4010)

This commit is contained in:
Ludovic Marcotte
2017-01-31 15:59:58 -05:00
parent d159b191a6
commit 15b277fa8e
4 changed files with 28 additions and 11 deletions
+8 -3
View File
@@ -784,7 +784,7 @@ static BOOL _singleStoreMode = NO;
return result;
}
- (GCSFolder *) folderAtPath: (NSString *) _path
- (NSDictionary *) recordAtPath: (NSString *) _path
{
NSMutableString *sql;
NSArray *fnames, *records;
@@ -841,8 +841,13 @@ static BOOL _singleStoreMode = NO;
[self debugWithFormat:@"found no record for path: '%@'", _path];
return nil;
}
return [self folderForRecord:record];
return record;
}
- (GCSFolder *) folderAtPath: (NSString *) _path
{
return [self folderForRecord: [self recordAtPath: _path]];
}
- (NSString *) baseTableNameWithUID: (NSString *) _uid