diff --git a/app/common/utils/crawl/service/UsedCarCrawlSingle.php b/app/common/utils/crawl/service/UsedCarCrawlSingle.php index 63b4744..c04cd10 100644 --- a/app/common/utils/crawl/service/UsedCarCrawlSingle.php +++ b/app/common/utils/crawl/service/UsedCarCrawlSingle.php @@ -42,7 +42,7 @@ class UsedCarCrawlSingle public function crawlCar(string $url){ $html = $this->fetchHtml($url); - if ($html === '') { + if ($html === '' || str_contains($html, '404 Not Found')) { throw new BusinessException("页面内容为空: {$url}"); }