fix crash for common event

Signed-off-by: zhongjianfei <zhongjianfei@huawei.com>
Change-Id: Ic2a49ac8337944f4faa6875b0ed4a968b2ac2137
This commit is contained in:
zhongjianfei
2022-03-26 20:14:23 +08:00
parent a32d8b874d
commit d673465752
@@ -2637,6 +2637,7 @@ napi_value CommonEventSubscriberConstructor(napi_env env, napi_callback_info inf
delete asyncCallbackInfo;
asyncCallbackInfo = nullptr;
}
CommonEventManager::UnSubscribeCommonEvent(subscriberInstance.first);
subscriberInstances.erase(subscriberInstance.first);
break;
}