From ed30549f6b2c4a2eb67d028b71cda2cfb4173315 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Sat, 28 Sep 2024 09:47:48 +0200 Subject: [PATCH] Feature/prepare permission to delete asset profile of currency (#3833) --- .../admin-market-data/admin-market-data.service.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/apps/client/src/app/components/admin-market-data/admin-market-data.service.ts b/apps/client/src/app/components/admin-market-data/admin-market-data.service.ts index 006bacb95..b1d7154e9 100644 --- a/apps/client/src/app/components/admin-market-data/admin-market-data.service.ts +++ b/apps/client/src/app/components/admin-market-data/admin-market-data.service.ts @@ -2,7 +2,10 @@ import { ConfirmationDialogType } from '@ghostfolio/client/core/notification/con import { NotificationService } from '@ghostfolio/client/core/notification/notification.service'; import { AdminService } from '@ghostfolio/client/services/admin.service'; import { ghostfolioScraperApiSymbolPrefix } from '@ghostfolio/common/config'; -import { getCurrencyFromSymbol, isCurrency } from '@ghostfolio/common/helper'; +import { + getCurrencyFromSymbol, + isDerivedCurrency +} from '@ghostfolio/common/helper'; import { AssetProfileIdentifier, AdminMarketDataItem @@ -74,7 +77,7 @@ export class AdminMarketDataService { return ( activitiesCount === 0 && !isBenchmark && - !isCurrency(getCurrencyFromSymbol(symbol)) && + !isDerivedCurrency(getCurrencyFromSymbol(symbol)) && !symbol.startsWith(ghostfolioScraperApiSymbolPrefix) ); }