fix erroneous exception handling
Merge pull request #2 from lociii/master

Fix erroneous exception handling