1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-05 21:45:23 +02:00

Revert batch upserting

This commit is contained in:
Zach Gollwitzer 2025-05-09 16:42:44 -04:00
parent 5d798fe0a0
commit 48a07d6158

View file

@ -63,9 +63,7 @@ module Security::Provided
is_invalid
end
valid_prices.each_slice(100) do |batch|
Security::Price.upsert_all(batch, unique_by: %i[security_id date currency])
end
Security::Price.upsert_all(valid_prices, unique_by: %i[security_id date currency])
end
def find_or_fetch_price(date: Date.current, cache: true)