Skip to content

Commit 8d21b0d

Browse files
authored
Upgrade Dependencies (#21)
1 parent 282e0f6 commit 8d21b0d

File tree

3 files changed

+460
-2588
lines changed

3 files changed

+460
-2588
lines changed

package.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,22 @@
1919
"/lib"
2020
],
2121
"dependencies": {
22-
"amplify-appsync-simulator": "^1.19.0",
23-
"amplify-util-mock": "^3.18.0",
24-
"aws-sdk": "^2.659.0",
22+
"amplify-appsync-simulator": "^1.20.2",
23+
"amplify-nodejs-function-runtime-provider": "^1.0.4",
24+
"aws-sdk": "^2.680.0",
2525
"axios": "^0.19.2",
26-
"cfn-resolver-lib": "^1.1.5",
26+
"cfn-resolver-lib": "^1.1.6",
2727
"dataloader": "^2.0.0",
28+
"extend": "^3.0.2",
2829
"lodash": "^4.17.15"
2930
},
3031
"devDependencies": {
3132
"@babel/cli": "^7.8.4",
32-
"@babel/core": "^7.9.0",
33-
"@babel/plugin-transform-modules-commonjs": "^7.9.0",
34-
"@babel/preset-env": "^7.9.5",
33+
"@babel/core": "^7.9.6",
34+
"@babel/plugin-transform-modules-commonjs": "^7.9.6",
35+
"@babel/preset-env": "^7.9.6",
3536
"babel-eslint": "^10.1.0",
36-
"eslint": "^6.7.1",
37+
"eslint": "^7.0.0",
3738
"eslint-config-airbnb-base": "^14.1.0",
3839
"eslint-plugin-import": "^2.20.2",
3940
"eslint-plugin-node": "^11.1.0",

src/getAppSyncConfig.js

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import {
22
AmplifyAppSyncSimulatorAuthenticationType as AuthTypes,
33
} from 'amplify-appsync-simulator';
4-
import { invoke } from 'amplify-util-mock/lib/utils/lambda/invoke';
4+
import { invoke } from 'amplify-nodejs-function-runtime-provider/lib/utils/invoke';
55
import fs from 'fs';
66
import { forEach } from 'lodash';
77
import path from 'path';
@@ -67,14 +67,12 @@ export default function getAppSyncConfig(context, appSyncConfig) {
6767
);
6868
return null;
6969
}
70-
const [fileName, handler] = func.handler.split('.');
7170
return {
7271
...dataSource,
7372
invoke: (payload) => invoke({
74-
packageFolder: context.serverless.config.servicePath,
75-
handler,
76-
fileName: path.join(context.options.location, fileName),
77-
event: payload,
73+
packageFolder: path.join(context.serverless.config.servicePath, context.options.location),
74+
handler: func.handler,
75+
event: JSON.stringify(payload),
7876
environment: {
7977
...(context.options.lambda.loadLocalEnv === true ? process.env : {}),
8078
...context.serverless.service.provider.environment,

0 commit comments

Comments
 (0)