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

Check event.user is not null #10

Merged
merged 1 commit into from
Sep 16, 2017
Merged

Conversation

fedealconada
Copy link
Contributor

This avoids problems when botpress uses both this and botpress-webhooks modules at the same time.

@CLAassistant
Copy link

CLAassistant commented Aug 15, 2017

CLA assistant check
All committers have signed the CLA.

fedealconada pushed a commit to fedealconada/botpress-api.ai that referenced this pull request Aug 15, 2017
I'm adding a line that checks if event.user is not null. This avoids problems when botpress uses both this and botpress-webhooks modules at the same time.
I'm moving up the line that checks if the event type is a message. This is because where it is now, it first tries to shortUserId with event.user.id and there is a possiblity that evet.user is undefined (e.g when we have botpress-webhooks installed and the webhook is triggered).
@slvnperron
Copy link
Member

Hey federico! Could you please sign the CLA so I can merge this?

Thanks

@jbuchacher
Copy link

jbuchacher commented Sep 15, 2017

Any chance this can get merged? Thanks in advance!

@slvnperron slvnperron merged commit 32391e8 into botpress:master Sep 16, 2017
@slvnperron
Copy link
Member

@jbuchacher Done and pushed in newest version!

@fedealconada
Copy link
Contributor Author

Nice :)

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

Successfully merging this pull request may close these issues.

None yet

4 participants