diff --git a/plugin.xml b/plugin.xml
index a563f3253..40479471b 100755
--- a/plugin.xml
+++ b/plugin.xml
@@ -27,12 +27,12 @@
-
+
-
+
diff --git a/src/ios/PushPlugin.m b/src/ios/PushPlugin.m
index 8649622e6..b8c9ca6da 100644
--- a/src/ios/PushPlugin.m
+++ b/src/ios/PushPlugin.m
@@ -119,6 +119,15 @@ - (void)unregister:(CDVInvokedUrlCommand*)command;
NSLog(@"unsubscribe from topic: %@", topic);
[pubSub unsubscribeFromTopic:topic];
}
+ } else if ([self usesFCM]){
+ [[FIRInstanceID instanceID] deleteIDWithHandler:^void(NSError *_Nullable error){
+ if (error) {
+ [self failWithMessage:command.callbackId withMsg:@"" withError:error];
+ } else {
+ [[UIApplication sharedApplication] unregisterForRemoteNotifications];
+ [self successWithMessage:command.callbackId withMsg:@"unregistered"];
+ }
+ }];
} else {
[[UIApplication sharedApplication] unregisterForRemoteNotifications];
[self successWithMessage:command.callbackId withMsg:@"unregistered"];