From 881000aa67a20e5366916252fd787cf2b44a9531 Mon Sep 17 00:00:00 2001 From: Abdullah Alfaraj <7842232+AbdullahAlfaraj@users.noreply.github.com> Date: Thu, 30 Nov 2023 20:23:33 +0300 Subject: [PATCH] fix: use comfy_url from from api --- typescripts/comfyui/comfyapi.ts | 2 +- typescripts/comfyui/comfyui.tsx | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/typescripts/comfyui/comfyapi.ts b/typescripts/comfyui/comfyapi.ts index f8114807..37381926 100644 --- a/typescripts/comfyui/comfyapi.ts +++ b/typescripts/comfyui/comfyapi.ts @@ -64,7 +64,7 @@ class ComfyAPI { async getHistory(prompt_id: string = '') { try { - const url = `http://127.0.0.1:8188/history/${prompt_id}` + const url = `${this.comfy_url}/history/${prompt_id}` const res = await requestGet(`${this.comfy_url}/history`) return res } catch (e) { diff --git a/typescripts/comfyui/comfyui.tsx b/typescripts/comfyui/comfyui.tsx index 8f05bc12..ba1cacad 100644 --- a/typescripts/comfyui/comfyui.tsx +++ b/typescripts/comfyui/comfyui.tsx @@ -109,7 +109,7 @@ export async function workflowEntries() { } export async function postPrompt(prompt: any) { try { - const url = 'http://127.0.0.1:8188/prompt' + const url = `${comfyapi.comfy_api.comfy_url}/prompt` const payload = { prompt: prompt, } @@ -1666,7 +1666,10 @@ root.render( //
- + {/* */}