mirror of
https://github.com/cosmicoptima/loom.git
synced 2026-07-22 07:40:25 +00:00
allow v1 in url
This commit is contained in:
parent
82600b4508
commit
32d8cf28ae
1 changed files with 1 additions and 0 deletions
1
main.ts
1
main.ts
|
|
@ -1164,6 +1164,7 @@ export default class LoomPlugin extends Plugin {
|
|||
if (!(url.startsWith("http://") || url.startsWith("https://")))
|
||||
url = "https://" + url;
|
||||
if (!url.endsWith("/")) url += "/";
|
||||
url = url.replace(/v1\//, "");
|
||||
url += "v1/completions";
|
||||
|
||||
const response = await fetch(url, {
|
||||
|
|
|
|||
Loading…
Reference in a new issue