Browse Source

Fix dates of manually entered market data in time zones other than UTC

pull/8495/head
Thomas Kaul 3 hours ago
parent
commit
3aa8dce713
  1. 7
      apps/api/src/app/endpoints/market-data/market-data.controller.ts

7
apps/api/src/app/endpoints/market-data/market-data.controller.ts

@ -111,9 +111,10 @@ export class MarketDataController {
}) })
); );
// Market data used to be stored in the time zone of the instance. Delete // Market data used to be stored at the given date in the time zone of the
// the items of the same dates that are not at midnight (UTC), so that they // instance. Delete the items at exactly these times, unless they are at
// do not take precedence over the updated ones. // midnight (UTC), so that they do not take precedence over the items at
// midnight (UTC). Any other items are kept.
const datesToDelete = data.marketData const datesToDelete = data.marketData
.map(({ date }) => { .map(({ date }) => {
return parseISO(date); return parseISO(date);

Loading…
Cancel
Save