From 62d567eac1a39df9b1db529794ec80d193349478 Mon Sep 17 00:00:00 2001 From: Lea Date: Thu, 27 Jul 2023 18:13:28 +0200 Subject: [PATCH] fix: handle user action errors correctly --- components/inspector/UserActions.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/inspector/UserActions.tsx b/components/inspector/UserActions.tsx index fb2946c..d948cf8 100644 --- a/components/inspector/UserActions.tsx +++ b/components/inspector/UserActions.tsx @@ -64,7 +64,7 @@ export function UserActions({ .catch((err) => toast({ title: "Failed to suspend user!", - description: err, + description: String(err), variant: "destructive", }) ) @@ -97,7 +97,7 @@ export function UserActions({ .catch((err) => toast({ title: "Failed to ban user!", - description: err, + description: String(err), variant: "destructive", }) ) @@ -155,7 +155,7 @@ export function UserActions({ .catch((err) => toast({ title: "Failed to send alert!", - description: err, + description: String(err), variant: "destructive", }) );