Revert "fix: resolve PHPStan static analysis warnings"

This reverts commit b885e644a8.
This commit is contained in:
xboard committed 2025-04-14 21:23:08 +08:00
1 parent b885e644a8
commit ea424ad0a8
84 files changed
+1190 -2330

No files matched your search

+2 -6
View File
@@ -2,14 +2,10 @@
namespace App\Http\Resources;
use App\Models\Order;
use App\Services\PlanService;
use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;
/**
* @mixin Order
*/
class OrderResource extends JsonResource
{
/**
@@ -21,8 +17,8 @@ class OrderResource extends JsonResource
{
return [
...parent::toArray($request),
'period' => PlanService::getLegacyPeriod((string)$this->period),
'plan' => $this->whenLoaded('plan', fn() => PlanResource::make($this->plan)),
'period' => PlanService::getLegacyPeriod($this->period),
'plan' => PlanResource::make($this->plan),
];
}
}