the-badger / badger

Gamification platform to motivate your team with badges, adventures & other cool stuff!
MIT License
80 stars 9 forks source link

Fix Slack notifier #119

Closed grena closed 7 years ago

grena commented 7 years ago

The SlackNotifier was not pinging the Slack webhook url. We need to wait for the promise otherwise the PHP process stops and kills the request.

We can bypass the wait() if we run this code in a kind of daemon, which is not the case here since it's an EventListener so in the main PHP Process.

Cf.: http://docs.guzzlephp.org/en/latest/faq.html?highlight=wait