update napi/settings/napi_settings_observer.cpp.

Signed-off-by: 侯志雄 <houzhixiong1@h-partners.com>
This commit is contained in:
侯志雄 2024-11-16 14:09:37 +00:00 committed by Gitee
parent 6081b2eb00
commit 084ade7c07
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -46,6 +46,7 @@ namespace Settings {
}
bool IsExistObserver(SettingsObserver* settingsObserver) {
std::lock_guard<std::mutex> lockGuard(g_observerMapMutex);
for (auto it = g_observerMap.begin(); it != g_observerMap.end(); ++it) {
if (&(*(it->second)) == settingsObserver) {
return true;