fixed a few exceptions to be caught in modern style