Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slackbot_worker throws Error when Slack Select menu is used #768

Closed
clintonhalpin opened this issue Apr 13, 2017 · 2 comments
Closed

Slackbot_worker throws Error when Slack Select menu is used #768

clintonhalpin opened this issue Apr 13, 2017 · 2 comments

Comments

@clintonhalpin
Copy link

clintonhalpin commented Apr 13, 2017

Testing out the new Slack Select menu's using a conversation. This line throws an error when sent a slack select response Slackbot_worker.js#L741

message.text = message.text.replace(direct_mention, '').replace(/^\s+/, '').replace(/^\:\s+/, '').replace(/^\s+/, '');

Error:

TypeError: Cannot read property 'replace' of undefined
    at Object.bot.findConversation

This is because message.text is not there and instead the response is in message.actions[ 0 ].select_values

Gist of Message Response

Details:

Version: 5.2
OS: OSX 10.3, Ubuntu 16.4
@matt-oakes
Copy link

This should be closed now I think.

@clintonhalpin
Copy link
Author

@matt-oakes Yep! I tested this yesterday it it worked for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants