alexa-js / alexa-app

A framework for Alexa (Amazon Echo) apps using Node.js
https://www.youtube.com/watch?v=pzM4jv7k7Rg
MIT License
1.03k stars 212 forks source link

Wrong object reference in README.md #360

Closed ghost closed 6 years ago

ghost commented 6 years ago

I'm currently using alexa-app on Lambda.

The doc says there is a dialogState property on the request object :

// return the intent's dialogState
String request.dialogState

I found this property to be undefined. However, it is defined (and correct) in the dialog object.

So the above example should be :

// return the intent's dialogState
String dialog.dialogState
dblock commented 6 years ago

Maybe PR a fix? Is it just a typo? Do we have code doing that? Thanks.

ghost commented 6 years ago

Yes, it's basically a typo imho, as other similar objects (slot and slotResolution) description follows a pattern like :

var <name> = <get>
<type> <propName1> = <name>.<property1>
<type> <propName2> = <name>.<property2>
<type> <propName3> = <name>.<property3>
...