mirror of
https://github.com/anomalyco/opencode.git
synced 2026-08-13 05:03:31 +00:00
adding timeout (#7128)
This commit is contained in:
parent
7d6ce6fc5e
commit
32e0b612d9
1 changed files with 1 additions and 1 deletions
|
|
@ -123,7 +123,7 @@ export namespace SystemPrompt {
|
|||
.then((x) => "Instructions from: " + p + "\n" + x),
|
||||
)
|
||||
const foundUrls = urls.map((url) =>
|
||||
fetch(url)
|
||||
fetch(url, { signal: AbortSignal.timeout(5000) })
|
||||
.then((res) => (res.ok ? res.text() : ""))
|
||||
.catch(() => "")
|
||||
.then((x) => (x ? "Instructions from: " + url + "\n" + x : "")),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue