Minor refactoring of exceptions
Merge remote-tracking branch 'origin/master'