From aaf950e2ad5c07d4423f9822e3a0ae9f7b8d2bdf Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Mon, 30 Mar 2020 16:09:32 +0530 Subject: re-format with prettier v2, fix HTML --- src/operations/errors.ts | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'src/operations/errors.ts') diff --git a/src/operations/errors.ts b/src/operations/errors.ts index 751a57111..50e68993b 100644 --- a/src/operations/errors.ts +++ b/src/operations/errors.ts @@ -64,7 +64,6 @@ export async function scrutinizeTalerJsonResponse( resp: HttpResponse, codec: Codec, ): Promise { - // FIXME: We should distinguish between different types of error status // to react differently (throttle, report permanent failure) @@ -82,7 +81,7 @@ export async function scrutinizeTalerJsonResponse( details: { httpStatusCode: resp.status, errorResponse: errorJson, - } + }, }); } catch (e) { const m = "could not parse response JSON"; @@ -91,7 +90,7 @@ export async function scrutinizeTalerJsonResponse( message: m, details: { status: resp.status, - } + }, }); } throw exc; @@ -101,13 +100,13 @@ export async function scrutinizeTalerJsonResponse( json = await resp.json(); } catch (e) { const m = "could not parse response JSON"; - throw new OperationFailedError({ - type: "network", - message: m, - details: { - status: resp.status, - } - }); + throw new OperationFailedError({ + type: "network", + message: m, + details: { + status: resp.status, + }, + }); } return codec.decode(json); } @@ -138,7 +137,7 @@ export async function guardOperationException( type: "exception", message: e.message, details: {}, - } + }; await onOpError(opErr); throw new OperationFailedAndReportedError(opErr); } -- cgit v1.2.3