Browse Source
Merge branch 'main' into bugfix/expand-date-range-to-cover-full-day-in-exchange-rate-calculation
pull/6311/head
Thomas Kaul
2 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
3 additions and
2 deletions
-
CHANGELOG.md
-
libs/common/src/lib/calculation-helper.ts
|
|
|
@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 |
|
|
|
|
|
|
|
### Fixed |
|
|
|
|
|
|
|
- Fixed an issue in the annualized performance calculation |
|
|
|
- Fixed an issue with the exchange rate calculation by expanding the date range to cover the full day (start to end of day) |
|
|
|
|
|
|
|
## 2.237.0 - 2026-02-08 |
|
|
|
|
|
|
|
@ -9,7 +9,7 @@ import { |
|
|
|
subDays, |
|
|
|
subYears |
|
|
|
} from 'date-fns'; |
|
|
|
import { isNumber } from 'lodash'; |
|
|
|
import { isFinite, isNumber } from 'lodash'; |
|
|
|
|
|
|
|
import { resetHours } from './helper'; |
|
|
|
import { DateRange } from './types'; |
|
|
|
@ -28,7 +28,7 @@ export function getAnnualizedPerformancePercent({ |
|
|
|
exponent |
|
|
|
); |
|
|
|
|
|
|
|
if (!isNaN(growthFactor)) { |
|
|
|
if (isFinite(growthFactor)) { |
|
|
|
return new Big(growthFactor).minus(1); |
|
|
|
} |
|
|
|
} |
|
|
|
|