From ee7c3037715dc0199cdc8866311454661c0d97c9 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Wed, 5 Aug 2026 17:38:25 +0200 Subject: [PATCH] Bugfix/handle exception in country weightings parsing of FMP service (#7544) * Handle exception in country weightings parsing * Update changelog --- CHANGELOG.md | 4 ++++ .../financial-modeling-prep.service.ts | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b541d5af..1ac12156e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Guarded the system tags against deletion and renaming in the tag management of the admin control panel +### Fixed + +- Handled an exception in the country weightings parsing of the _Financial Modeling Prep_ service + ## 3.42.0 - 2026-08-04 ### Changed diff --git a/apps/api/src/services/data-provider/financial-modeling-prep/financial-modeling-prep.service.ts b/apps/api/src/services/data-provider/financial-modeling-prep/financial-modeling-prep.service.ts index 05df65ad1..f7f2e7eb9 100644 --- a/apps/api/src/services/data-provider/financial-modeling-prep/financial-modeling-prep.service.ts +++ b/apps/api/src/services/data-provider/financial-modeling-prep/financial-modeling-prep.service.ts @@ -178,7 +178,7 @@ export class FinancialModelingPrepService aliases: FinancialModelingPrepService.countriesMapping, name: countryName }), - weight: parseFloat(weightPercentage.slice(0, -1)) / 100 + weight: parseFloat(`${weightPercentage}`) / 100 }; });