Skip to content

Commit

Permalink
fix: use index.html as start page
Browse files Browse the repository at this point in the history
  • Loading branch information
leo6104 committed Feb 4, 2021
1 parent 2d603c6 commit 3438b95
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions ios/Plugin/CodePush.m
Original file line number Diff line number Diff line change
Expand Up @@ -419,9 +419,8 @@ - (NSString*)getConfigLaunchUrl

- (NSURL *)getStartPageURLForLocalPackage:(NSString*)packageLocation {
if (packageLocation) {
NSString* startPage = [self getConfigLaunchUrl];
NSString* libraryLocation = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0];
NSArray* realLocationArray = @[libraryLocation, packageLocation, @"www", startPage];
NSArray* realLocationArray = @[libraryLocation, packageLocation, @"www/index.html"];
NSString* realStartPageLocation = [NSString pathWithComponents:realLocationArray];
if ([[NSFileManager defaultManager] fileExistsAtPath:realStartPageLocation]) {
// Fixes WKWebView unable to load start page from CodePush update directory
Expand Down

0 comments on commit 3438b95

Please sign in to comment.