fix: use kpi dict from _kpi_for_period instead of removed local vars
Some checks are pending
NordaBiz Tests / Unit & Integration Tests (push) Waiting to run
NordaBiz Tests / E2E Tests (Playwright) (push) Blocked by required conditions
NordaBiz Tests / Smoke Tests (Production) (push) Blocked by required conditions
NordaBiz Tests / Send Failure Notification (push) Blocked by required conditions

The refactor to _kpi_for_period() removed the local variables but
the return dict still referenced them. Replace with the kpi dict.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Maciej Pienczyn 2026-03-10 19:29:41 +01:00
parent d7baa1e588
commit 8c6715e915

View File

@ -1225,12 +1225,7 @@ def _tab_overview(db, start_date, days):
return {
'filter_type': filter_type,
'kpi': {
'active_users': active_users,
'sessions': total_sessions,
'pageviews': total_pageviews,
'bounce_rate': bounce_rate,
},
'kpi': kpi,
'chart_data': {
'labels': chart_labels,
'sessions': chart_sessions,