修复error_detect