From 3999e61a2014c0844d15d0e9120168b8ebcb9c6d Mon Sep 17 00:00:00 2001 From: "iVampireSP.com" Date: Mon, 13 Feb 2023 18:41:13 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=20=E4=BD=BF=E7=94=A8=20?= =?UTF-8?q?=E5=AE=89=E5=85=A8=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Http/Controllers/Api/HostController.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/app/Http/Controllers/Api/HostController.php b/app/Http/Controllers/Api/HostController.php index df0af65..75d787b 100644 --- a/app/Http/Controllers/Api/HostController.php +++ b/app/Http/Controllers/Api/HostController.php @@ -47,12 +47,7 @@ public function destroy(HostRequest $request, Host $host): JsonResponse } } - // 如果时间大于 5 分钟,不满 1 小时 - if (! $host->isCycle() && now()->diffInMinutes($host->updated_at) > 5 && now()->diffInMinutes($host->updated_at) < 60) { - $host->cost(); - } - - dispatch(new HostJob($host, 'delete')); + $host->safeDelete(); return $this->deleted($host); }