mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-25 08:09:38 +02:00
Fix account sync when prices missing (#1127)
This commit is contained in:
parent
525439e44d
commit
cf861ccff9
2 changed files with 62 additions and 1 deletions
|
@ -16,7 +16,7 @@ class Issue::PricesMissing < Issue
|
|||
missing_prices.each do |ticker, dates|
|
||||
next unless issuable.owns_ticker?(ticker)
|
||||
|
||||
oldest_date = dates.min
|
||||
oldest_date = dates.min.to_date
|
||||
expected_price_count = (oldest_date..Date.current).count
|
||||
prices = Security::Price.find_prices(ticker: ticker, start_date: oldest_date)
|
||||
stale = false if prices.count < expected_price_count
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue