From 3dcf557e496bc5807e804fa5d14acefb06433b63 Mon Sep 17 00:00:00 2001 From: Adrien Date: Wed, 22 May 2024 09:57:03 +0200 Subject: [PATCH] fix --- Chat.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Chat.go b/Chat.go index e041aa6..f1cb366 100644 --- a/Chat.go +++ b/Chat.go @@ -301,7 +301,7 @@ func ClearChatHandler(c *fiber.Ctx) error { // Popover stuff func LoadUsageKPIHandler(c *fiber.Ctx) error { - if !checkIfLogin() { + if !checkIfLogin() || !checkIfHaveKey() { return c.SendString("") } var TotalUsage float32 @@ -388,7 +388,7 @@ func LoadKeysHandler(c *fiber.Ctx) error { } func LoadModelSelectionHandler(c *fiber.Ctx) error { - if !checkIfLogin() { + if !checkIfLogin() || !checkIfHaveKey() { return c.SendString("") } openaiExists, anthropicExists, mistralExists, groqExists, gooseaiExists, googleExists := getExistingKeys()