class ElasticAPM::CentralConfig
def assign(update)
def assign(update) # For each updated option, store the original value, # unless already stored update.each_key do |key| @modified_options[key] ||= config.get(key.to_sym)&.value end # If the new update doesn't set a previously modified option, # revert it to the original @modified_options.each_key do |key| next if update.key?(key) update[key] = @modified_options.delete(key) end @config.replace_options(update) end