Created
January 1, 2018 20:53
-
-
Save jwhitehorn/fa9b568450a905c2888f106c0b456db4 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| - (BOOL) isUpdatePending { | |
| NSArray *documentPaths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); | |
| NSString *documentsDirectoryPath = [documentPaths objectAtIndex:0]; | |
| NSString *filePath = [documentsDirectoryPath stringByAppendingPathComponent:@"updated.db"]; | |
| NSFileManager *fileManager = [NSFileManager defaultManager]; | |
| return [fileManager fileExistsAtPath:filePath]; | |
| } | |
| - (BOOL) hasPerformedInitialSync { | |
| NSArray *documentPaths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); | |
| NSString *documentsDirectoryPath = [documentPaths objectAtIndex:0]; | |
| NSString *filePath = [documentsDirectoryPath stringByAppendingPathComponent:@"database.db"]; | |
| NSFileManager *fileManager = [NSFileManager defaultManager]; | |
| return [fileManager fileExistsAtPath:filePath]; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment