minor error reporting improvement