Permalink
Browse files

Drop RestKitCoreData.momd from the resources bundle. It is not curren…

…tly viable to load the entities because you cannot reference entities in one model from another within Xcode.
  • Loading branch information...
1 parent 7ff8746 commit a740a9ce3ba6da196f88299ac44ac7ea3c602636 @blakewatters blakewatters committed Mar 15, 2012
@@ -104,24 +104,8 @@ - (id)initWithStoreFilename:(NSString *)storeFilename inDirectory:(NSString *)ni
// NOTE: allBundles permits Core Data setup in unit tests
nilOrManagedObjectModel = [NSManagedObjectModel mergedModelFromBundles:[NSBundle allBundles]];
}
- NSMutableArray* allManagedObjectModels = [[NSMutableArray alloc] init];
- [allManagedObjectModels addObject:nilOrManagedObjectModel];
-
- NSBundle *restKitResourcesBundle = [NSBundle restKitResourcesBundle];
- if (restKitResourcesBundle) {
- NSURL* rkCoreDataLibraryMOMURL = [restKitResourcesBundle URLForResource:@"RestKitCoreData"
- withExtension:@"momd"];
- NSManagedObjectModel* rkCoreDataLibraryMOM = [[NSManagedObjectModel alloc] initWithContentsOfURL:rkCoreDataLibraryMOMURL];
- if (rkCoreDataLibraryMOM) {
- [allManagedObjectModels addObject:rkCoreDataLibraryMOM];
- [rkCoreDataLibraryMOM release];
- } else {
- RKLogWarning(@"Unable to find RestKitCoreData.momd within the RestKitResources.bundle");
- }
- }
-
+ NSMutableArray* allManagedObjectModels = [NSMutableArray arrayWithObject:nilOrManagedObjectModel];
_managedObjectModel = [[NSManagedObjectModel modelByMergingModels:allManagedObjectModels] retain];
- [allManagedObjectModels release];
if (nilOrNameOfSeedDatabaseInMainBundle) {
[self createStoreIfNecessaryUsingSeedDatabase:nilOrNameOfSeedDatabaseInMainBundle];
@@ -514,7 +514,6 @@
259C3027151280A1003066A2 /* grayArrow@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 25EC1AE314F8022600C3CF3F /* grayArrow@2x.png */; };
259C3028151280A1003066A2 /* whiteArrow.png in Resources */ = {isa = PBXBuildFile; fileRef = 25EC1AE414F8022600C3CF3F /* whiteArrow.png */; };
259C3029151280A1003066A2 /* whiteArrow@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 25EC1AE514F8022600C3CF3F /* whiteArrow@2x.png */; };
- 259C302A151280B0003066A2 /* RestKitCoreData.xcdatamodeld in Resources */ = {isa = PBXBuildFile; fileRef = 25EC1ADB14F8022600C3CF3F /* RestKitCoreData.xcdatamodeld */; };
25A34245147D8AAA0009758D /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25A34244147D8AAA0009758D /* Security.framework */; };
25B408261491CDDC00F21111 /* RKDirectory.h in Headers */ = {isa = PBXBuildFile; fileRef = 25B408241491CDDB00F21111 /* RKDirectory.h */; settings = {ATTRIBUTES = (Public, ); }; };
25B408271491CDDC00F21111 /* RKDirectory.h in Headers */ = {isa = PBXBuildFile; fileRef = 25B408241491CDDB00F21111 /* RKDirectory.h */; settings = {ATTRIBUTES = (Public, ); }; };
@@ -2572,7 +2571,6 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- 259C302A151280B0003066A2 /* RestKitCoreData.xcdatamodeld in Resources */,
259C3022151280A1003066A2 /* blackArrow.png in Resources */,
259C3023151280A1003066A2 /* blackArrow@2x.png in Resources */,
259C3024151280A1003066A2 /* blueArrow.png in Resources */,
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
- <key>NSManagedObjectModel_CurrentVersionName</key>
- <string>RestKitCoreData</string>
- <key>NSManagedObjectModel_VersionHashes</key>
- <dict>
- <key>RestKitCoreData</key>
- <dict>
- <key>RKDummyEntity</key>
- <data>
- /6y2a2HzepaKWU6jyRbFbNGg8ziPU4p6yr40qUG6bx8=
- </data>
- <key>RKSearchWord</key>
- <data>
- 8ILMzYCnYe8uGzdLHqnxo6RUX+ifEi9tjcRr4dRZL24=
- </data>
- <key>RKSearchableManagedObject</key>
- <data>
- mkPRCudukXRO5vBX5pUU6ldJVkhf7bE7wkbmDOlxJDo=
- </data>
- </dict>
- </dict>
-</dict>
-</plist>

0 comments on commit a740a9c

Please sign in to comment.