Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 2bc94c4

Browse files
authored
Revert "Load iOS dart bundle by URL fallback (#22997)" (#23054)
This reverts commit 9df2157.
1 parent 360a16a commit 2bc94c4

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

shell/platform/darwin/ios/framework/Source/FlutterDartProject.mm

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,6 @@
4343
if (bundle == nil) {
4444
bundle = [NSBundle bundleWithIdentifier:[FlutterDartProject defaultBundleIdentifier]];
4545
}
46-
if (bundle == nil) {
47-
// The bundle isn't loaded and can't be found by bundle ID. Find it by path.
48-
bundle = [NSBundle bundleWithURL:[NSBundle.mainBundle.privateFrameworksURL
49-
URLByAppendingPathComponent:@"App.framework"]];
50-
}
5146
if (bundle == nil) {
5247
bundle = mainBundle;
5348
}
@@ -244,16 +239,11 @@ + (NSString*)flutterAssetsName:(NSBundle*)bundle {
244239
bundle = [NSBundle bundleWithIdentifier:[FlutterDartProject defaultBundleIdentifier]];
245240
}
246241
if (bundle == nil) {
247-
// The bundle isn't loaded and can't be found by bundle ID. Find it by path.
248-
bundle = [NSBundle bundleWithURL:[NSBundle.mainBundle.privateFrameworksURL
249-
URLByAppendingPathComponent:@"App.framework"]];
242+
bundle = [NSBundle mainBundle];
250243
}
251244
NSString* flutterAssetsName = [bundle objectForInfoDictionaryKey:@"FLTAssetsPath"];
252-
if (bundle == nil) {
253-
bundle = [NSBundle mainBundle];
245+
if (flutterAssetsName == nil) {
254246
flutterAssetsName = @"Frameworks/App.framework/flutter_assets";
255-
} else if (flutterAssetsName == nil) {
256-
flutterAssetsName = @"flutter_assets";
257247
}
258248
return flutterAssetsName;
259249
}

0 commit comments

Comments
 (0)