From 6c69ba1904d2a0b80aa42d9f3fa4767637099942 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Sat, 18 Oct 2025 09:37:38 +0200 Subject: [PATCH] Refactoring --- .../src/app/endpoints/benchmarks/benchmarks.service.ts | 8 ++++++-- apps/client/src/app/services/data.service.ts | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/apps/api/src/app/endpoints/benchmarks/benchmarks.service.ts b/apps/api/src/app/endpoints/benchmarks/benchmarks.service.ts index c11cbe003..03ff32c21 100644 --- a/apps/api/src/app/endpoints/benchmarks/benchmarks.service.ts +++ b/apps/api/src/app/endpoints/benchmarks/benchmarks.service.ts @@ -4,7 +4,11 @@ import { BenchmarkService } from '@ghostfolio/api/services/benchmark/benchmark.s import { ExchangeRateDataService } from '@ghostfolio/api/services/exchange-rate-data/exchange-rate-data.service'; import { MarketDataService } from '@ghostfolio/api/services/market-data/market-data.service'; import { DATE_FORMAT, parseDate, resetHours } from '@ghostfolio/common/helper'; -import { AssetProfileIdentifier, Filter } from '@ghostfolio/common/interfaces'; +import { + AssetProfileIdentifier, + BenchmarkMarketDataDetailsResponse, + Filter +} from '@ghostfolio/common/interfaces'; import { DateRange, UserWithSettings } from '@ghostfolio/common/types'; import { Injectable, Logger } from '@nestjs/common'; @@ -39,7 +43,7 @@ export class BenchmarksService { startDate: Date; user: UserWithSettings; withExcludedAccounts?: boolean; - } & AssetProfileIdentifier) { + } & AssetProfileIdentifier): Promise { const marketData: { date: string; value: number }[] = []; const userCurrency = user.settings.settings.baseCurrency; const userId = user.id; diff --git a/apps/client/src/app/services/data.service.ts b/apps/client/src/app/services/data.service.ts index 4f252ffd8..98a36a81f 100644 --- a/apps/client/src/app/services/data.service.ts +++ b/apps/client/src/app/services/data.service.ts @@ -365,7 +365,7 @@ export class DataService { range: DateRange; startDate: Date; withExcludedAccounts?: boolean; - } & AssetProfileIdentifier): Observable { + } & AssetProfileIdentifier) { let params = this.buildFiltersAsQueryParams({ filters }); params = params.append('range', range);