better error handling for web context provider
This commit is contained in:
parent
99b767d653
commit
8a7d7ce78c
1 changed files with 2 additions and 1 deletions
|
|
@ -35,7 +35,8 @@ export default class WebContextProvider extends BaseContextProvider {
|
|||
}),
|
||||
});
|
||||
if (!resp.ok) {
|
||||
throw new Error("Failed to fetch web context");
|
||||
const text = await resp.text();
|
||||
throw new Error(`Failed to fetch web context: ${text}`);
|
||||
}
|
||||
const json = await resp.json();
|
||||
return json;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue