fixed a bug where 'appdata' wasn't supported as a root Google Drive path

This commit is contained in:
Stefan Reitshamer 2016-01-12 19:18:59 -05:00
parent 8084b69b31
commit 254e815eac

View file

@ -90,7 +90,7 @@ CWL_SYNTHESIZE_SINGLETON_FOR_CLASS(GoogleDriveFactory)
[lock lock];
NSMutableDictionary *folderIdsByPath = [folderIdDictionariesByRefreshToken objectForKey:theRefreshToken];
if (folderIdsByPath == nil) {
folderIdsByPath = [NSMutableDictionary dictionaryWithObject:@"root" forKey:@"/"];
folderIdsByPath = [NSMutableDictionary dictionaryWithObjectsAndKeys:@"root", @"/", @"appdata", @"/appdata", nil];
[folderIdDictionariesByRefreshToken setObject:folderIdsByPath forKey:theRefreshToken];
}
NSString *ret = [[[folderIdsByPath objectForKey:thePath] copy] autorelease];