Browse Source
Feature/add todo for emergency fund positions value calculation (#3684)
* Add todo
pull/3713/head
Thomas Kaul
7 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
2 additions and
0 deletions
-
apps/api/src/app/portfolio/portfolio.service.ts
|
|
@ -1394,6 +1394,8 @@ export class PortfolioService { |
|
|
|
}: { |
|
|
|
holdings: PortfolioDetails['holdings']; |
|
|
|
}) { |
|
|
|
// TODO: Use current value of activities instead of holdings
|
|
|
|
// tagged with EMERGENCY_FUND_TAG_ID
|
|
|
|
const emergencyFundHoldings = Object.values(holdings).filter(({ tags }) => { |
|
|
|
return ( |
|
|
|
tags?.some(({ id }) => { |
|
|
|