Check error.stack exists (Fixes #30)

Fixes #30.