fixes a nasty bug

Signed-off-by: AlexsJones <alexsimonjones@gmail.com>
This commit is contained in:
AlexsJones
2023-03-24 14:19:16 +00:00
parent c7e8f00458
commit 80a99757f9
2 changed files with 8 additions and 4 deletions

View File

@@ -13,10 +13,10 @@ type OpenAIClient struct {
func (c *OpenAIClient) Configure(token string) error {
client := openai.NewClient(token)
if client == nil {
return errors.New("error creating OpenAI client")
}
c.client = client
return nil
}