From 445ab12854a458efa61e8a882f4b01e5706e26b1 Mon Sep 17 00:00:00 2001 From: Andy Leap Date: Wed, 26 Apr 2023 19:01:04 -0400 Subject: [PATCH] send config update notification before unblocking --- OptimizelySDK/Config/PollingProjectConfigManager.cs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/OptimizelySDK/Config/PollingProjectConfigManager.cs b/OptimizelySDK/Config/PollingProjectConfigManager.cs index 4024ce58..da07daef 100644 --- a/OptimizelySDK/Config/PollingProjectConfigManager.cs +++ b/OptimizelySDK/Config/PollingProjectConfigManager.cs @@ -1,4 +1,4 @@ -/* +/* * Copyright 2019-2020, 2022-2023 Optimizely * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -25,7 +25,7 @@ namespace OptimizelySDK.Config { /// - /// Abstract class that implements ProjectConfigManager interface and provides + /// Abstract class that implements ProjectConfigManager interface and provides /// basic scheduling and caching. /// Instances of this class, must implement the method /// which is responsible for fetching a given ProjectConfig. @@ -181,11 +181,10 @@ public bool SetConfig(ProjectConfig projectConfig) CurrentProjectConfig = projectConfig; SetOptimizelyConfig(CurrentProjectConfig); - // SetResult raise exception if called again, that's why Try is used. - CompletableConfigManager.TrySetResult(true); - NotifyOnProjectConfigUpdate?.Invoke(); + // SetResult raise exception if called again, that's why Try is used. + CompletableConfigManager.TrySetResult(true); return true; }