From 7e3ff94ed1d28cdb4724cd5b58c4b946f307827c Mon Sep 17 00:00:00 2001 From: QuentinArguillere Date: Tue, 25 May 2021 13:42:15 +0200 Subject: [PATCH] Properly enable push notifications on core start, and fix typo (true=>pushEnabled) --- Classes/LinphoneManager.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Classes/LinphoneManager.m b/Classes/LinphoneManager.m index d2ac42af7..c82a19037 100644 --- a/Classes/LinphoneManager.m +++ b/Classes/LinphoneManager.m @@ -1287,12 +1287,13 @@ void popup_link_account_cb(LinphoneAccountCreator *creator, LinphoneAccountCreat - (void)startLinphoneCore { bool pushEnabled = [self lpConfigIntForKey:@"proxy" inSection:@"push_notification_allowed"]; + linphone_core_set_push_notification_enabled([LinphoneManager getLc], pushEnabled); const MSList *accountsList = linphone_core_get_account_list(theLinphoneCore); while (accountsList) { LinphoneAccount * account = accountsList->data; LinphoneAccountParams * accountParams = linphone_account_params_clone(linphone_account_get_params(account)); linphone_account_params_set_push_notification_allowed(accountParams, pushEnabled); - linphone_account_params_set_remote_push_notification_allowed(accountParams, true); + linphone_account_params_set_remote_push_notification_allowed(accountParams, pushEnabled); LinphonePushNotificationConfig *pushConfig = linphone_account_params_get_push_notification_config(accountParams); #ifdef DEBUG