diff --git a/apps/dokploy/components/layouts/side.tsx b/apps/dokploy/components/layouts/side.tsx index d2daaf6b2..8d84e260c 100644 --- a/apps/dokploy/components/layouts/side.tsx +++ b/apps/dokploy/components/layouts/side.tsx @@ -627,90 +627,93 @@ function SidebarLogo() { /> - {org.ownerId === session?.user?.id && ( -
- + {org.ownerId === session?.user?.id && ( + <> + + { + await deleteOrganization({ + organizationId: org.id, }) - .catch((error) => { - toast.error( - error?.message || - "Error setting default organization", - ); - }); - }} - title={ - isDefault - ? "Default organization" - : "Set as default" - } - > - {isDefault ? ( - - ) : ( - - )} - - - { - await deleteOrganization({ - organizationId: org.id, - }) - .then(() => { - refetch(); - toast.success( - "Organization deleted successfully", - ); - }) - .catch((error) => { - toast.error( - error?.message || - "Error deleting organization", - ); - }); - }} - > - - -
- )} + + + + )} + ); })}