Clean up
This commit is contained in:
parent
9e4a49d811
commit
c47578bd3e
@ -79,13 +79,13 @@ export class CurrentRateService {
|
||||
const result = [];
|
||||
for (const symbol of symbols) {
|
||||
result.push({
|
||||
symbol,
|
||||
date: today,
|
||||
marketPrice: this.exchangeRateDataService.toCurrency(
|
||||
dataResultProvider?.[symbol]?.marketPrice ?? 0,
|
||||
dataResultProvider?.[symbol]?.currency,
|
||||
userCurrency
|
||||
),
|
||||
symbol: symbol
|
||||
)
|
||||
});
|
||||
}
|
||||
return result;
|
||||
|
@ -300,8 +300,8 @@ export class PortfolioCalculator {
|
||||
|
||||
return {
|
||||
...overall,
|
||||
hasErrors: hasErrors || overall.hasErrors,
|
||||
positions
|
||||
positions,
|
||||
hasErrors: hasErrors || overall.hasErrors
|
||||
};
|
||||
}
|
||||
|
||||
@ -426,11 +426,11 @@ export class PortfolioCalculator {
|
||||
}
|
||||
return {
|
||||
currentValue,
|
||||
totalInvestment,
|
||||
grossPerformance,
|
||||
hasErrors,
|
||||
totalInvestment,
|
||||
grossPerformancePercentage:
|
||||
grossPerformancePercentage.div(completeInitialValue),
|
||||
hasErrors
|
||||
grossPerformancePercentage.div(completeInitialValue)
|
||||
};
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user