implement 'error' event
more elegant 'error' implementation
Merge pull request #3 from kamholz/master

make error handling possible