This commit is contained in:
2023-11-28 05:15:42 +08:00
parent efdfccbb5b
commit c31f6a860a
48 changed files with 475 additions and 26294 deletions

View File

@@ -44,8 +44,7 @@ public static function handle(int $url_to_crawl_id)
if ($response->successful()) {
$raw_html = $response->body();
if ($enable_proxy)
{
if ($enable_proxy) {
$cost = calculate_smartproxy_cost(round(strlen($raw_html) / 1024, 2), 'rotating_global');
$service_cost_usage = new ServiceCostUsage;
@@ -57,7 +56,6 @@ public static function handle(int $url_to_crawl_id)
$service_cost_usage->save();
}
} else {
$raw_html = null;
$response->throw();