From 356ae058baa444ae52a9b14e809b03b4831f5218 Mon Sep 17 00:00:00 2001 From: Ben Loe Date: Tue, 2 Jul 2024 15:40:10 -0400 Subject: [PATCH] undo accidental change --- src/mods/hooks/useDeleteStandaloneModDefinitionAction.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mods/hooks/useDeleteStandaloneModDefinitionAction.ts b/src/mods/hooks/useDeleteStandaloneModDefinitionAction.ts index 23e5884933..e8027a7678 100644 --- a/src/mods/hooks/useDeleteStandaloneModDefinitionAction.ts +++ b/src/mods/hooks/useDeleteStandaloneModDefinitionAction.ts @@ -33,7 +33,7 @@ import { Events } from "@/telemetry/events"; function useDeleteStandaloneModDefinitionAction( modViewItem: ModViewItem, ): (() => void) | null { - const { mod, status } = modViewItem; + const { mod, sharing, status } = modViewItem; const modals = useModals(); const [deleteStandaloneModDefinition] = useDeleteStandaloneModDefinitionMutation(); @@ -41,6 +41,7 @@ function useDeleteStandaloneModDefinitionAction( const canDelete = isStandaloneModComponent(mod) && + sharing.source.type === "Personal" && // If the status is active, there is still likely a copy of the mod component saved on our server. // However, we want the user to have to deactivate the mod before deleting it from the server !isActive;