From 34d1a34b10f4386865f3c241c5ae4026d2bfd8bd Mon Sep 17 00:00:00 2001
From: AAGaming <aa@mail.catvibers.me>
Date: Sat, 5 Aug 2023 01:11:43 -0400
Subject: Migrate most of frontend callServerMethod usage over to websocket

---
 frontend/src/components/modals/PluginUninstallModal.tsx | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

(limited to 'frontend/src/components/modals/PluginUninstallModal.tsx')

diff --git a/frontend/src/components/modals/PluginUninstallModal.tsx b/frontend/src/components/modals/PluginUninstallModal.tsx
index e7ecbc99..e9c243b6 100644
--- a/frontend/src/components/modals/PluginUninstallModal.tsx
+++ b/frontend/src/components/modals/PluginUninstallModal.tsx
@@ -1,6 +1,8 @@
 import { ConfirmModal } from 'decky-frontend-lib';
 import { FC } from 'react';
 
+import { uninstallPlugin } from '../../plugin';
+
 interface PluginUninstallModalProps {
   name: string;
   title: string;
@@ -14,7 +16,7 @@ const PluginUninstallModal: FC<PluginUninstallModalProps> = ({ name, title, butt
     <ConfirmModal
       closeModal={closeModal}
       onOK={async () => {
-        await window.DeckyPluginLoader.callServerMethod('uninstall_plugin', { name });
+        await uninstallPlugin(name);
         // uninstalling a plugin resets the hidden setting for it server-side
         // we invalidate here so if you re-install it, you won't have an out-of-date hidden filter
         await window.DeckyPluginLoader.hiddenPluginsService.invalidate();
-- 
cgit v1.2.3

