From 21f9c6609e94a3342c8a0fc14865050436f45f14 Mon Sep 17 00:00:00 2001 From: Brian LeRoux Date: Tue, 21 Dec 2021 10:58:41 -0800 Subject: [PATCH] fixes ruby --- src/write-functions/templates/events.js | 2 +- src/write-functions/templates/http.js | 2 +- src/write-functions/templates/queues.js | 2 +- src/write-functions/templates/scheduled.js | 2 +- src/write-functions/templates/tables-streams.js | 2 +- src/write-functions/templates/ws.js | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/write-functions/templates/events.js b/src/write-functions/templates/events.js index 1f85a67..3e63694 100644 --- a/src/write-functions/templates/events.js +++ b/src/write-functions/templates/events.js @@ -13,7 +13,7 @@ export async function handler (event: object) { }` let ruby = `# ${learn} -def handler(event) +def handler(event:, context:) puts event true end` diff --git a/src/write-functions/templates/http.js b/src/write-functions/templates/http.js index af9973a..798eb2f 100644 --- a/src/write-functions/templates/http.js +++ b/src/write-functions/templates/http.js @@ -98,7 +98,7 @@ exports.handler = async function http (req) { }` let ruby = path => `# ${learn} -def handler(req, context) +def handler(event:, context:) { statusCode: 200, headers: { diff --git a/src/write-functions/templates/queues.js b/src/write-functions/templates/queues.js index 111ace2..51cf4f3 100644 --- a/src/write-functions/templates/queues.js +++ b/src/write-functions/templates/queues.js @@ -13,7 +13,7 @@ export async function handler (event: object) { }` let ruby = `# ${learn} -def handler(event) +def handler(event:, context:) puts event true end` diff --git a/src/write-functions/templates/scheduled.js b/src/write-functions/templates/scheduled.js index 19e0aa2..cfd49eb 100644 --- a/src/write-functions/templates/scheduled.js +++ b/src/write-functions/templates/scheduled.js @@ -13,7 +13,7 @@ export async function handler (event: object) { }` let ruby = `# ${learn} -def handler(event) +def handler(event:, context:) puts event true end` diff --git a/src/write-functions/templates/tables-streams.js b/src/write-functions/templates/tables-streams.js index 7a3e863..300b985 100644 --- a/src/write-functions/templates/tables-streams.js +++ b/src/write-functions/templates/tables-streams.js @@ -13,7 +13,7 @@ export async function handler (event: object) { }` let ruby = `# ${learn} -def handler(event) +def handler(event:, context:) puts event true end` diff --git a/src/write-functions/templates/ws.js b/src/write-functions/templates/ws.js index 65e76a8..7c5e1b9 100644 --- a/src/write-functions/templates/ws.js +++ b/src/write-functions/templates/ws.js @@ -13,7 +13,7 @@ export async function handler (event: object) { }` let ruby = `# ${learn} -def handler(event) +def handler(event:, context:) puts event {statusCode: 200} end`