vscode extension sends events without clientId, for whatever reason

This commit is contained in:
Simon Knott 2024-11-08 13:40:43 +01:00
parent e1d3dc224b
commit cb76898d65
No known key found for this signature in database
GPG key ID: 8CEDC00028084AEC

View file

@ -112,8 +112,10 @@ async function doFetch(event: FetchEvent): Promise<Response> {
return snapshotServer.serveClosestScreenshot(relativePath, url.searchParams); return snapshotServer.serveClosestScreenshot(relativePath, url.searchParams);
} }
if (!client) if (!client) {
throw new Error('expected client to be defined for all non-iframe requests. soemthing went wrong'); // expected client to be defined for all non-iframe requests. something went wrong
return fetch(event.request);
}
if (relativePath === '/contexts') { if (relativePath === '/contexts') {
try { try {