From d9cc091b98bee60eb39aab897b34d2ecc4283a90 Mon Sep 17 00:00:00 2001 From: Aditya Darma Date: Sun, 5 May 2024 16:53:23 +0800 Subject: [PATCH] update resource --- src/Services/BaseService.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Services/BaseService.php b/src/Services/BaseService.php index c71c459..0441099 100644 --- a/src/Services/BaseService.php +++ b/src/Services/BaseService.php @@ -134,10 +134,10 @@ public function toJson(): JsonResponse /** * Convert resource to json response * - * @param $resource - * @return static + * @param string $resource + * @return JsonResponse */ - public function toJsonFromResource($resource) + public function toJsonFromResource(string $resource): JsonResponse { return $this->resource($resource)->toJson(); } @@ -145,10 +145,10 @@ public function toJsonFromResource($resource) /** * Convert to json data with resource * - * @param $resource + * @param string $resource * @return static */ - public function resource($resource): static + public function resource(string $resource): static { if ($this->data) { // Simple Paginate