1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-07-19 13:19:39 +02:00

Fix provider guards for start price

This commit is contained in:
Zach Gollwitzer 2025-05-19 15:19:41 -04:00
parent a262a749fe
commit ab5bce3462
2 changed files with 4 additions and 4 deletions

View file

@ -18,8 +18,8 @@ class ExchangeRate::Importer
return return
end end
if clear_cache && provider_rates.empty? if provider_rates.empty?
Rails.logger.warn("Could not clear cache for #{from} to #{to} between #{start_date} and #{end_date} because provider returned no rates") Rails.logger.warn("Could not fetch rates for #{from} to #{to} between #{start_date} and #{end_date} because provider returned no rates")
return return
end end

View file

@ -18,8 +18,8 @@ class Security::Price::Importer
return 0 return 0
end end
if clear_cache && provider_prices.empty? if provider_prices.empty?
Rails.logger.warn("Could not clear cache for #{security.ticker} between #{start_date} and #{end_date} because provider returned no prices") Rails.logger.warn("Could not fetch prices for #{security.ticker} between #{start_date} and #{end_date} because provider returned no prices")
return 0 return 0
end end