From dc2c8f384e6ed1a9fb5a0a9af65aa3e27fab8536 Mon Sep 17 00:00:00 2001 From: GotPPay Date: Tue, 23 Jan 2018 12:15:04 +0100 Subject: [PATCH] use foreach instead of map --- backend/models/alexa.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/models/alexa.js b/backend/models/alexa.js index 61b390c..c9a32e2 100644 --- a/backend/models/alexa.js +++ b/backend/models/alexa.js @@ -34,7 +34,7 @@ module.exports = { destinationEmail = activeSkill.contactEmail; let listOfPossibleQuestions = ''; - activeSkill.intents.map (intent => { + activeSkill.intents.forEach(intent => { if (intent.questions.length > 0 && intent.intentExplanation) { listOfPossibleQuestions += intent.intentExplanation + @@ -45,6 +45,8 @@ module.exports = { } }); + console.log(listOfPossibleQuestions); + //Handler for launch requestconsole.log() handlers = { LaunchRequest: function () {