From d5713cd4bad1fe5680686845cb3b3628bcd2e504 Mon Sep 17 00:00:00 2001 From: Martin Micunda Date: Sat, 1 Jun 2019 00:55:07 +0100 Subject: [PATCH] fix(apiGatewayProxyResultMock): set empty string as default value for body of apiGatewayProxyResultM --- index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.ts b/index.ts index ee6a013..eceef0c 100644 --- a/index.ts +++ b/index.ts @@ -81,7 +81,7 @@ export const apiGatewayProxyResultMock = ( statusCode = 200 ): APIGatewayProxyResult => ({ statusCode, - body: JSON.stringify(body || '{}'), + body: body ? JSON.stringify(body) : '', headers: headers || undefined, });