howdyai / botkit-storage-mongo

A MongoDB storage driver for Botkit
MIT License
54 stars 42 forks source link

Catching mongo error #26

Closed davidvexel closed 7 years ago

davidvexel commented 7 years ago

Sometimes, when I run my bot and I didn't notice that mongo process was down, I don't get any error messages from the botkit storage, just a weird behavior on my bot, until I realize mongo is turned off.

With this simple catch, you can check the mongo connection before running any bot.