Added error output

Closes #16