fix(prompt): fixed issue with wrong api key

This commit is contained in:
Stan Girard 2023-12-03 01:22:38 +01:00
parent fed4bfc713
commit 882a10c459
2 changed files with 4 additions and 2 deletions

View File

@ -4,10 +4,12 @@ from modules.prompt.repository.prompts_interface import (
DeletePromptResponse,
PromptsInterface,
)
from models.settings import get_supabase_client
class Prompts(PromptsInterface):
def __init__(self, supabase_client):
def __init__(self):
supabase_client = get_supabase_client()
self.db = supabase_client
def create_prompt(self, prompt):

View File

@ -16,7 +16,7 @@ class PromptService:
def __init__(self):
supabase_client = get_supabase_client()
self.repository = Prompts(supabase_client)
self.repository = Prompts()
def create_prompt(self, prompt: CreatePromptProperties) -> Prompt:
return self.repository.create_prompt(prompt)