Sorry, dumb question number 2 today. Is it possible to determine if a file is contained within the App Bundle? I can access files no problem, i.e.,
NSString *p
pathForResource will return nil if the resource does not exist. Checking again with NSFileManager is redundant.
Obj-C:
if (![[NSBundle mainBundle] pathForResource:@"FileName" ofType:@"plist"]) {
NSLog(@"The path could not be created.");
return;
}
Swift 4:
guard Bundle.main.path(forResource: "FileName", ofType: "plist") != nil else {
print("The path could not be created.")
return
}