diff --git a/src/api/query-hooks/health.tsx b/src/api/query-hooks/health.tsx index 353f40299..c78bf28fd 100644 --- a/src/api/query-hooks/health.tsx +++ b/src/api/query-hooks/health.tsx @@ -22,10 +22,9 @@ export function useGetCheckDetails(checkId?: string) { return useQuery({ queryKey: ["check", "details", checkId], queryFn: async () => { - console.log("checkId", checkId); const res = await getHealthCheckDetails(checkId!); return res; }, - enabled: checkId !== undefined + enabled: !!checkId }); } diff --git a/src/components/Canary/CanaryPopup/CheckRunNow.tsx b/src/components/Canary/CanaryPopup/CheckRunNow.tsx index 5e9e5c6a2..2432e5db5 100644 --- a/src/components/Canary/CanaryPopup/CheckRunNow.tsx +++ b/src/components/Canary/CanaryPopup/CheckRunNow.tsx @@ -8,7 +8,6 @@ import { Button } from "@flanksource-ui/ui/Buttons/Button"; import { useMutation } from "@tanstack/react-query"; import { FaSpinner } from "react-icons/fa"; import { VscDebugRerun } from "react-icons/vsc"; -import { toastSuccess } from "../../Toast/toast"; // admin, editor, responder, commander roles are allowed to run checks const allowedRoles = ["admin", "editor", "responder", "commander"]; @@ -27,11 +26,7 @@ export default function CheckRunNow({ const { isLoading, mutate: runNow } = useMutation({ mutationFn: runHealthCheckNow, onSuccess: (data) => { - toastSuccess("You have successfully initiated the check run."); onSuccessfulRun(data.data); - }, - onError: (error) => { - console.error("Error running check", error); } }); diff --git a/src/ui/Icons/Icon.tsx b/src/ui/Icons/Icon.tsx index 4934b7ca1..6e79052a7 100644 --- a/src/ui/Icons/Icon.tsx +++ b/src/ui/Icons/Icon.tsx @@ -832,8 +832,6 @@ export function Icon({ return "text-gray-700"; }, [iconWithColor]); - console.log("IconSVG", IconSVG, colorClassName); - if (name && (name.startsWith("http:") || name.startsWith("https://"))) { // eslint-disable-next-line @next/next/no-img-element return {alt};