Adding proper default error handlers