Refactored Exceptions

Fixes #65.