mirror of
https://github.com/Kizuren/statusPage.git
synced 2026-01-07 06:59:42 +01:00
Bug correction, signal should be set within the fetch options. (before endpoint.request to allow overwriting it)
This commit is contained in:
parent
a82459000a
commit
84e85f0e85
1 changed files with 4 additions and 1 deletions
|
|
@ -71,7 +71,10 @@ while(true) {
|
|||
try {
|
||||
performance.clearResourceTimings();
|
||||
start = performance.now();
|
||||
let response = await fetch(endpoint.url, endpoint.request, { signal: AbortSignal.timeout(config.timeout) });
|
||||
let response = await fetch(endpoint.url, {
|
||||
signal: AbortSignal.timeout(config.timeout),
|
||||
...endpoint.request,
|
||||
});
|
||||
let content = await response.text();
|
||||
await delay(0); // Ensures that the entry was registered.
|
||||
let perf = performance.getEntriesByType('resource')[0];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue