From c58a44d96cee47d43e9f3f815e3e281ea1ac5726 Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 30 Oct 2025 00:55:57 +0000 Subject: [PATCH] [PM-26676] Add organizationId to ReportState interface Add optional organizationId field to ReportState to track which organization the state belongs to. This enables the scan operator to detect organization changes and handle them appropriately. Part of fixing the conflict between: - PM-27291 (preserve critical flags during report generation) - PM-26676 (clear data when switching organizations) The organizationId field allows us to distinguish between: 1. Null data from loading states (same org) - preserve critical flags 2. Null data from org switches - clear old org data --- .../src/dirt/reports/risk-insights/models/report-models.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/bitwarden_license/bit-common/src/dirt/reports/risk-insights/models/report-models.ts b/bitwarden_license/bit-common/src/dirt/reports/risk-insights/models/report-models.ts index 93955c7dbfb..8722203329d 100644 --- a/bitwarden_license/bit-common/src/dirt/reports/risk-insights/models/report-models.ts +++ b/bitwarden_license/bit-common/src/dirt/reports/risk-insights/models/report-models.ts @@ -112,6 +112,7 @@ export interface ReportState { loading: boolean; error: string | null; data: RiskInsightsData | null; + organizationId?: string; } // TODO Make Versioned models for structure changes