Skip to content

Commit

Permalink
fix(storage, ios): fix usage of storage plugin with an isolate (#10106)
Browse files Browse the repository at this point in the history
  • Loading branch information
Lyokone committed Dec 15, 2022
1 parent d0b6fcf commit 86f2463
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ + (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar> *)registrar {
binaryMessenger:[registrar messenger]];

FLTFirebaseStoragePlugin *instance = [FLTFirebaseStoragePlugin sharedInstance];
if (instance.channel != nil) {
NSLog(@"FLTFirebaseStorage was already registered. If using isolates, you can safely ignore "
@"this message.");
return;
}
instance.channel = channel;
#if TARGET_OS_OSX
// TODO(Salakar): Publish does not exist on MacOS version of FlutterPluginRegistrar.
Expand Down

0 comments on commit 86f2463

Please sign in to comment.