Skip to content

Commit faa45c4

Browse files
author
Kevin Elko
committed
Reorganize
1 parent 62c3682 commit faa45c4

File tree

1 file changed

+3
-2
lines changed
  • packages/remote-config/src

1 file changed

+3
-2
lines changed

packages/remote-config/src/api.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,13 +137,14 @@ export async function fetchConfig(remoteConfig: RemoteConfig): Promise<void> {
137137
* @param fetchResponse - The fetchResponse containing the config values and eTag
138138
* with which to hydrate the internal state.
139139
*/
140-
export async function setRenderedConfig(remoteConfig: RemoteConfig, fetchResponse: FetchResponse) {
140+
export async function setConfigState(remoteConfig: RemoteConfig, fetchResponse: FetchResponse) {
141141
const rc = getModularInstance(remoteConfig) as RemoteConfigImpl;
142142
await Promise.all([
143143
rc._storage.setLastSuccessfulFetchResponse(fetchResponse),
144-
rc._storage.setActiveConfigEtag(fetchResponse.eTag || ''),
145144
rc._storageCache.setLastSuccessfulFetchTimestampMillis(Date.now()),
146145
rc._storageCache.setLastFetchStatus('success'),
146+
// TODO - maybe we just call activate() here?
147+
rc._storage.setActiveConfigEtag(fetchResponse.eTag || ''),
147148
rc._storageCache.setActiveConfig(fetchResponse.config || {}),
148149
]);
149150
}

0 commit comments

Comments
 (0)