diff --git a/superset-frontend/src/components/ReportModal/HeaderReportActionsDropdown/index.tsx b/superset-frontend/src/components/ReportModal/HeaderReportActionsDropdown/index.tsx index 78fb6bb0c73f8..aa4d0c20d8167 100644 --- a/superset-frontend/src/components/ReportModal/HeaderReportActionsDropdown/index.tsx +++ b/superset-frontend/src/components/ReportModal/HeaderReportActionsDropdown/index.tsx @@ -61,10 +61,8 @@ export default function HeaderReportActionsDropDown({ any, UserWithPermissionsAndRoles >(state => state.user || state.explore?.user); - const [ - currentReportDeleting, - setCurrentReportDeleting, - ] = useState(null); + const [currentReportDeleting, setCurrentReportDeleting] = + useState(null); const theme = useTheme(); const [showModal, setShowModal] = useState(false); const toggleActiveKey = async (data: AlertObject, checked: boolean) => { @@ -82,7 +80,7 @@ export default function HeaderReportActionsDropDown({ if (!isFeatureEnabled(FeatureFlag.ALERT_REPORTS)) { return false; } - if (!user) { + if (!user?.userId) { // this is in the case that there is an anonymous user. return false; }