diff --git a/awx/ui_next/src/screens/NotificationTemplate/NotificationTemplate.jsx b/awx/ui_next/src/screens/NotificationTemplate/NotificationTemplate.jsx index cc32c9eb64..005dd0e40b 100644 --- a/awx/ui_next/src/screens/NotificationTemplate/NotificationTemplate.jsx +++ b/awx/ui_next/src/screens/NotificationTemplate/NotificationTemplate.jsx @@ -45,9 +45,9 @@ function NotificationTemplate({ setBreadcrumb, i18n }) { useEffect(() => { fetchTemplate(); - }, [fetchTemplate]); + }, [fetchTemplate, location.pathname]); - if (error) { + if (!isLoading && error) { return ( @@ -66,7 +66,7 @@ function NotificationTemplate({ setBreadcrumb, i18n }) { ); } - const showCardHeader = !isLoading && !location.pathname.endsWith('edit'); + const showCardHeader = !location.pathname.endsWith('edit'); const tabs = [ { name: (