From ca29ee8e41bf34b7fa4d261a2c9d2a809b97f874 Mon Sep 17 00:00:00 2001 From: Stanislav Chzhen Date: Thu, 7 Mar 2024 14:41:45 +0300 Subject: [PATCH] all: upd chlog --- CHANGELOG.md | 2 ++ client/src/components/Dashboard/index.js | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 72f8f825..8c727184 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,6 +61,7 @@ NOTE: Add new changes BELOW THIS COMMENT. ### Fixed +- Statistics for 7 days displayed by day on the dashboard graph ([#6712]). - Missing IP addresses in logs when querying for domain names from the ignore lists. - Wrong algorithm for caching bootstrapped upstream addresses ([#6723]). @@ -74,6 +75,7 @@ NOTE: Add new changes BELOW THIS COMMENT. [#6610]: https://github.com/AdguardTeam/AdGuardHome/issues/6610 [#6679]: https://github.com/AdguardTeam/AdGuardHome/issues/6679 [#6711]: https://github.com/AdguardTeam/AdGuardHome/issues/6711 +[#6712]: https://github.com/AdguardTeam/AdGuardHome/issues/6712 [go-toolchain]: https://go.dev/blog/toolchain [go-1.21.8]: https://groups.google.com/g/golang-announce/c/5pwGVUPoMbg diff --git a/client/src/components/Dashboard/index.js b/client/src/components/Dashboard/index.js index 5d0aa4b8..ea0499bc 100644 --- a/client/src/components/Dashboard/index.js +++ b/client/src/components/Dashboard/index.js @@ -55,7 +55,9 @@ const Dashboard = ({ return t('stats_disabled_short'); } - if (stats.timeUnits === TIME_UNITS.HOURS && stats.interval === 604800000) { + const msIn7Days = 604800000; + + if (stats.timeUnits === TIME_UNITS.HOURS && stats.interval === msIn7Days) { return t('for_last_days', { count: msToDays(stats.interval) }); }