diff --git a/CHANGELOG.md b/CHANGELOG.md index 9aa155ade..cdd0e3ee3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed +- Fixed an issue in the performance and chart calculation of today - Fixed the alignment of the value component in the admin control panel ## 1.202.0 - 07.10.2022 diff --git a/apps/api/src/app/portfolio/portfolio-calculator.ts b/apps/api/src/app/portfolio/portfolio-calculator.ts index 46fe092bb..eee617708 100644 --- a/apps/api/src/app/portfolio/portfolio-calculator.ts +++ b/apps/api/src/app/portfolio/portfolio-calculator.ts @@ -14,6 +14,7 @@ import { format, isAfter, isBefore, + isSameDay, isSameMonth, isSameYear, max, @@ -187,7 +188,9 @@ export class PortfolioCalculator { day = addDays(day, step); } - dates.push(resetHours(end)); + if (!isSameDay(last(dates), end)) { + dates.push(resetHours(end)); + } for (const item of transactionPointsBeforeEndDate[firstIndex - 1].items) { dataGatheringItems.push({