This repository was archived by the owner on May 20, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -57,9 +57,7 @@ + (NSURL *)bundleURLForResource:(NSString *)resourceName
57
57
NSError *error;
58
58
NSString *packageFile = [CodePushPackage getCurrentPackageBundlePath: &error];
59
59
NSURL *binaryJsBundleUrl = [[NSBundle mainBundle ] URLForResource: resourceName withExtension: resourceExtension];
60
- NSDictionary *binaryFileAttributes = [[NSFileManager defaultManager ] attributesOfItemAtPath: [binaryJsBundleUrl path ] error: nil ];
61
- NSDate *binaryDate = [binaryFileAttributes objectForKey: NSFileModificationDate ];
62
- [self saveBinaryBundleDate: binaryDate];
60
+ [self saveBinaryBundleDate: binaryJsBundleUrl];
63
61
64
62
NSString *logMessageFormat = @" Loading JS bundle from %@ " ;
65
63
@@ -124,10 +122,12 @@ + (BOOL)isUsingTestConfiguration
124
122
return testConfigurationFlag;
125
123
}
126
124
127
- + (void )saveBinaryBundleDate : (NSDate *)binaryBundleDate
125
+ + (void )saveBinaryBundleDate : (NSURL *)binaryJsBundleUrl
128
126
{
127
+ NSDictionary *binaryFileAttributes = [[NSFileManager defaultManager ] attributesOfItemAtPath: [binaryJsBundleUrl path ] error: nil ];
128
+ NSDate *binaryDate = [binaryFileAttributes objectForKey: NSFileModificationDate ];
129
129
NSUserDefaults *preferences = [NSUserDefaults standardUserDefaults ];
130
- [preferences setObject: binaryBundleDate forKey: BinaryBundleDateKey];
130
+ [preferences setObject: binaryDate forKey: BinaryBundleDateKey];
131
131
[preferences synchronize ];
132
132
}
133
133
You can’t perform that action at this time.
0 commit comments