The following code is outputting The operation couldn’t be completed. (Cocoa error 256.)
and the filenames NSArray is null/empty. There should be files in this folder, any ideas whats broken?
NSError *error;
NSFileManager *fm = [NSFileManager defaultManager];
filenames = [fm contentsOfDirectoryAtPath:[[NSBundle mainBundle] pathForResource:@"files" ofType:nil] error:&error];
NSLog(@"%@", [error localizedDescription]);
EDIT
[[NSBundle mainBundle] pathForResource:@"files" ofType:nil] is returning null for some reason