Skip to content

Commit 25b3844

Browse files
Update invoke.js
1 parent b385699 commit 25b3844

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

lib/plugins/aws/invoke.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,13 @@ class AwsInvoke {
102102

103103
log(invocationReply) {
104104
if (invocationReply.Payload) {
105-
const payloadStr = invocationReply.Payload instanceof Uint8Array
106-
? new TextDecoder().decode(invocationReply.Payload)
107-
: Buffer.isBuffer(invocationReply.Payload)
108-
? invocationReply.Payload.toString()
109-
: invocationReply.Payload;
110-
105+
const payloadStr =
106+
invocationReply.Payload instanceof Uint8Array
107+
? new TextDecoder().decode(invocationReply.Payload)
108+
: Buffer.isBuffer(invocationReply.Payload)
109+
? invocationReply.Payload.toString()
110+
: invocationReply.Payload;
111+
111112
const response = JSON.parse(payloadStr);
112113

113114
writeText(JSON.stringify(response, null, 4));

0 commit comments

Comments
 (0)