fix on_error