Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Prev Previous commit
Next Next commit
remove null check on ios and update bundle id
  • Loading branch information
szakarias committed May 2, 2017
commit dea913d638bc4f08a2e6b573d617568f0c07172a
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
);
PRODUCT_BUNDLE_IDENTIFIER = com.yourcompany.pathProviderExample;
PRODUCT_BUNDLE_IDENTIFIER = io.flutter.plugins.pathProviderExample;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Debug;
Expand All @@ -459,7 +459,7 @@
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
);
PRODUCT_BUNDLE_IDENTIFIER = com.yourcompany.pathProviderExample;
PRODUCT_BUNDLE_IDENTIFIER = io.flutter.plugins.pathProviderExample;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
Expand Down
18 changes: 2 additions & 16 deletions packages/path-provider/ios/Classes/PathProviderPlugin.m
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,9 @@ - (instancetype)initWithController:(FlutterViewController *)controller {
[channel setMethodCallHandler:^(FlutterMethodCall *call,
FlutterResult result) {
if ([@"getTemporaryDirectory" isEqualToString:call.method]) {
NSString* dirPath = [self getTemporaryDirectory];
if (dirPath) {
result(dirPath);
} else {
result([FlutterError errorWithCode:@"ERROR"
message:@"Could not find temp dir"
details:nil]);
}
result([self getTemporaryDirectory]);
} else if ([@"getApplicationDocumentsDirectory" isEqualToString:call.method]) {
NSString* dirPath = [self getApplicationDocumentsDirectory];
if (dirPath) {
result(dirPath);
} else {
result([FlutterError errorWithCode:@"ERROR"
message:@"Could not find app documents dir"
details:nil]);
}
result([self getApplicationDocumentsDirectory]);
} else {
result(FlutterMethodNotImplemented);
}
Expand Down