Skip to content

Commit

Permalink
Merge pull request #58 from Flagsmith/fix/stop_repeated_calls_to_upda…
Browse files Browse the repository at this point in the history
…ted_environment

fix: Stop repeated calls to update environment when polling manager is set
  • Loading branch information
zachaysan authored Apr 17, 2024
2 parents 4523496 + 472b86d commit 58ba907
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/flagsmith.rb
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ def load_offline_handler
def environment_data_polling_manager
return nil unless @config.local_evaluation?

update_environment
update_environment if @environment_data_polling_manager.nil?

@environment_data_polling_manager ||= Flagsmith::EnvironmentDataPollingManager.new(
self, environment_refresh_interval_seconds
Expand Down

0 comments on commit 58ba907

Please sign in to comment.