Handle reduce of empty array (#3446)

This commit is contained in:
Thomas Kaul 2024-06-01 11:14:34 +02:00 committed by GitHub
parent 69d85eadfd
commit 0e08d8830e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -78,7 +78,7 @@ export class ExchangeRateDataService {
);
const lastDateString = dateStrings.reduce((a, b) => {
return a > b ? a : b;
});
}, undefined);
let previousExchangeRate =
exchangeRatesByCurrency[`${currency}${targetCurrency}`]?.[