diff --git a/src/lib/features/metrics/client-metrics/metrics-service-v2.ts b/src/lib/features/metrics/client-metrics/metrics-service-v2.ts index 50796e4c2a..47b40c83cb 100644 --- a/src/lib/features/metrics/client-metrics/metrics-service-v2.ts +++ b/src/lib/features/metrics/client-metrics/metrics-service-v2.ts @@ -223,10 +223,13 @@ export default class ClientMetricsServiceV2 { let hours: HourBucket[]; let metrics: IClientMetricsEnv[]; if (this.flagResolver.isEnabled('extendedUsageMetrics')) { + // if we're in the daily range we need to add one more day + const normalizedHoursBack = + hoursBack > 48 ? hoursBack + 24 : hoursBack; metrics = await this.clientMetricsStoreV2.getMetricsForFeatureToggleV2( featureName, - hoursBack, + normalizedHoursBack, ); hours = hoursBack > 48