Skip to content

Commit

Permalink
Merge pull request #666 from refinery-labs/fix-node-temporal-runtime
Browse files Browse the repository at this point in the history
Fix Node Temporal runtime
  • Loading branch information
freeqaz authored Oct 28, 2020
2 parents cd67c7e + c4210cb commit 698a4ef
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions api/runtimes/nodejs10.x/index.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
const main = require("./refinery_main").main;
const main = require('./refinery_main').main;

exports.handler = async (event) => {
const result = await main(
event.hasOwnProperty("block_input") ? event['block_input'] : {},
event.hasOwnProperty("backpack") ? event['backpack'] : {}
);
const response = {
result: result,
backpack: backpack
};
return JSON.stringify(response)
const backpack = event.hasOwnProperty('backpack') ? event['backpack'] : {};
const result = await main(
event.hasOwnProperty('block_input') ? event['block_input'] : {},
backpack
);
const response = {
result: result,
backpack: backpack
};
return JSON.stringify(response)
};

0 comments on commit 698a4ef

Please sign in to comment.