Skip to content

Commit 5c8f6f0

Browse files
authored
Add serverless object to handler (#7)
1 parent 6edb59d commit 5c8f6f0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ custom:
3636
Based on the configuration above the plugin will search for a file `scripts/output.js` with the following content:
3737

3838
```js
39-
function handler (data) {
39+
function handler (data, serverless) {
4040
console.log('Received Stack Output', data)
4141
}
4242

src/plugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ class StackOutputPlugin {
4848
const func = splits.pop() || ''
4949

5050
return new Promise((resolve) => {
51-
require(splits.join('.'))[func](data)
51+
require(splits.join('.'))[func](data, this.serverless)
5252

5353
resolve()
5454
})

0 commit comments

Comments
 (0)