Added in some exception handlers.