XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet
公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/gpt4free

fix: update HTML paths to use STATIC_URL in render function

b0a2e7be
hlohaus <983577+hlohaus@users.noreply.github.com>
提交于

代码差异

1 个文件 +1 -0
Modified g4f/gui/server/website.py +1 -0
@@ -67,6 +67,7 @@ def render(filename = "home", download_url: str = GITHUB_URL):
67 67 if not cache_file.endswith(".js") and response.headers.get("Content-Type", "").startswith("application/javascript"):
68 68 cache_file += ".js"
69 69 html = response.text
70 html = html.replace('"dist/', f"{STATIC_URL}/dist/")
70 71 html = html.replace('"/dist/', f"{STATIC_URL}/dist/")
71 72 html = html.replace('"../dist/', f"{STATIC_URL}/dist/")
72 73 # html = html.replace(JSDELIVR_URL, "/")