From 44b4d1a458e9e893fa93a1f8c90260fd1aa6fcf0 Mon Sep 17 00:00:00 2001 From: Steve Faulkner Date: Mon, 14 Nov 2016 18:02:55 -0500 Subject: [PATCH] Revert "@wip Warn on missing description field" --- migration.md | 3 +-- src/generate-function/templates.js | 9 ++++----- src/util/load.js | 4 ---- 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/migration.md b/migration.md index 83179ac..6897ead 100644 --- a/migration.md +++ b/migration.md @@ -21,8 +21,7 @@ example: ```json { - "FunctionName": "$PROJECT_NAME-$FUNCTION_NAME", - "Description": "" + "FunctionName": "$PROJECT_NAME-$FUNCTION_NAME" } ``` diff --git a/src/generate-function/templates.js b/src/generate-function/templates.js index c7af45d..f77eb81 100644 --- a/src/generate-function/templates.js +++ b/src/generate-function/templates.js @@ -3,9 +3,9 @@ export function index () { export function handler(event, context, callback) { // Replace below with your own code! - console.log(JSON.stringify(event)) - console.log(JSON.stringify(context)) - console.log(JSON.stringify(config)) + console.log(event) + console.log(context) + console.log(config) callback(null, { statusCode: 200, headers: {}, body: 'success!' }) }` @@ -28,8 +28,7 @@ export function event () { export function lambda (name) { let obj = { - FunctionName: name, - Description: '' + FunctionName: name } return JSON.stringify(obj, null, 2) diff --git a/src/util/load.js b/src/util/load.js index ea3837d..45fd035 100644 --- a/src/util/load.js +++ b/src/util/load.js @@ -32,10 +32,6 @@ export function lambdaConfig (name) { const functionConfig = readJSONSync(`functions/${name}/lambda.json`) const projectConfig = readJSONSync(`lambda.json`) - if (!functionConfig.Description) { - console.log(`Warning: "functions/${name}/lambda.json" is missing a "Description" field.`) - } - return Object.assign(projectConfig, functionConfig) }