Fixed a missing await when throwing server side errors

Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2021-11-18 14:19:28 +01:00
parent ddfdcd2b44
commit 9f21236a29
3 changed files with 9 additions and 3 deletions
+2 -2
View File
@@ -187,7 +187,7 @@ export class ScaffolderClient implements ScaffolderApi {
});
if (!response.ok) {
throw ResponseError.fromResponse(response);
throw await ResponseError.fromResponse(response);
}
return await response.json();
@@ -302,7 +302,7 @@ export class ScaffolderClient implements ScaffolderApi {
});
if (!response.ok) {
throw ResponseError.fromResponse(response);
throw await ResponseError.fromResponse(response);
}
return await response.json();