diff --git a/frontend/src/scenes/project/CreateProjectModal.tsx b/frontend/src/scenes/project/CreateProjectModal.tsx index e1471df2d495e..878a12f7c0a05 100644 --- a/frontend/src/scenes/project/CreateProjectModal.tsx +++ b/frontend/src/scenes/project/CreateProjectModal.tsx @@ -16,7 +16,6 @@ export function CreateProjectModal({ inline?: boolean }): JSX.Element { const { createTeam } = useActions(teamLogic) - const { loadCurrentOrganization } = useActions(organizationLogic) const { currentOrganization } = useValues(organizationLogic) const { reportProjectCreationSubmitted } = useActions(eventUsageLogic) const [name, setName] = useState('') @@ -32,7 +31,6 @@ export function CreateProjectModal({ const handleSubmit = (): void => { createTeam({ name, is_demo: false }) reportProjectCreationSubmitted(currentOrganization?.teams ? currentOrganization.teams.length : 0, name.length) - loadCurrentOrganization() closeModal() } diff --git a/frontend/src/scenes/teamLogic.tsx b/frontend/src/scenes/teamLogic.tsx index 17def88cb67ef..be21abb60f6da 100644 --- a/frontend/src/scenes/teamLogic.tsx +++ b/frontend/src/scenes/teamLogic.tsx @@ -206,6 +206,9 @@ export const teamLogic = kea([ ], })), listeners(({ actions }) => ({ + createTeamSuccess: () => { + organizationLogic.actions.loadCurrentOrganization() + }, deleteTeam: async ({ team }) => { try { await api.delete(`api/projects/${team.id}`)