Open Source Wealth Management Software. Angular + NestJS + Prisma + Nx + TypeScript 🤍
TypeScript angularetffinancefintechghostfoliohacktoberfestinvestingnestjsosspersonal-financeportfolioprismasoftwarestocktrackertradingtypescriptwealth-managementweb
Feature/add validation of search results in eod historical data service (#2883)
Thomas Kaul693791d11375
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 59c1e176ab..56e0d93856 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0### Added- Added the holdings table to the account detail dialog+- Validated the currency of the search results in the _EOD Historical Data_ service## 2.40.0 - 2024-01-15diff --git a/apps/api/src/services/data-provider/eod-historical-data/eod-historical-data.service.ts b/apps/api/src/services/data-provider/eod-historical-data/eod-historical-data.service.tsindex 24607ab4d5..649b0c3546 100644--- a/apps/api/src/services/data-provider/eod-historical-data/eod-historical-data.service.ts+++ b/apps/api/src/services/data-provider/eod-historical-data/eod-historical-data.service.ts@@ -277,8 +277,9 @@ export class EodHistoricalDataService implements DataProviderInterface {return {items: searchResult- .filter(({ symbol }) => {- return !symbol.endsWith('.FOREX');+ .filter(({ currency, symbol }) => {+ // Remove 'NA' currency and exchange rates+ return currency?.length === 3 && !symbol.endsWith('.FOREX');}).map(({