Skip to content

Commit

Permalink
Load remote config values in web right away. (#1147)
Browse files Browse the repository at this point in the history
Fixes #1108
  • Loading branch information
Jonas-Sander authored Nov 6, 2023
1 parent c3c9b6a commit d35d096
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions app/lib/main/plugin_initializations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,12 @@ class PluginInitializations {
});

try {
if (flavor == Flavor.dev) {
// Since we depend on some values from our Remote Config in the dev
// environment, we can't use the "Load new values for next startup"
// strategy.
// Since the web is never really restarted in the web, we need to fetch
// the remote configuration right away.
//
// We depend on some values from our Remote Config in the dev environment,
// so we can't use the "Load new values for next startup" strategy.
if (PlatformCheck.isWeb || flavor == Flavor.dev) {
await remoteConfiguration.fetch();
await remoteConfiguration.activate();
} else {
Expand Down

0 comments on commit d35d096

Please sign in to comment.