DCtheTall / twilly

A library which provides an abstract syntax for designing Twilio SMS interactions. Designed for use with Node.js and Express
MIT License
52 stars 3 forks source link

Add type checking of hooks when `twilly()` is called. #6

Open DCtheTall opened 5 years ago

DCtheTall commented 5 years ago

It would be nice if twilly() type checked the functions passed as hooks to avoid TypeErrors. Before I left it up to the user, but it might be less cryptic for debugging if twilly() just did an early exit and threw an error.

I would appreciate a PR if anyone is willing. Otherwise I can do it at some point.