From 56836d05fe7354852ca93636352f429480e818c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=B5=9C=EC=A4=80=ED=9D=A0?= Date: Mon, 18 Nov 2024 14:12:10 +0900 Subject: [PATCH] cfmgrv4 init...4 --- app/Services/Cloudflare/FirewallService.php | 2 +- app/Services/Cloudflare/RecordService.php | 2 +- app/Services/Cloudflare/ZoneService.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/Services/Cloudflare/FirewallService.php b/app/Services/Cloudflare/FirewallService.php index 98766f3..a219a83 100644 --- a/app/Services/Cloudflare/FirewallService.php +++ b/app/Services/Cloudflare/FirewallService.php @@ -25,7 +25,7 @@ class FirewallService extends CloudflareService } return $this->_parent_entity; } - private function setParentEntity(mixed $parent_entity): void + private function setParentEntity(ZoneEntity $parent_entity): void { $this->_parent_entity = $parent_entity; $account_entity = $this->getAccountModel()->getEntityByPK($this->getParentEntity()->getParent()); diff --git a/app/Services/Cloudflare/RecordService.php b/app/Services/Cloudflare/RecordService.php index c3e9cac..323530c 100644 --- a/app/Services/Cloudflare/RecordService.php +++ b/app/Services/Cloudflare/RecordService.php @@ -25,7 +25,7 @@ class RecordService extends CloudflareService } return $this->_parent_entity; } - private function setParentEntity(mixed $parent_entity): void + private function setParentEntity(ZoneEntity $parent_entity): void { $this->_parent_entity = $parent_entity; $account_entity = $this->getAccountModel()->getEntityByPK($this->getParentEntity()->getParent()); diff --git a/app/Services/Cloudflare/ZoneService.php b/app/Services/Cloudflare/ZoneService.php index 020e003..1f78f45 100644 --- a/app/Services/Cloudflare/ZoneService.php +++ b/app/Services/Cloudflare/ZoneService.php @@ -30,7 +30,7 @@ class ZoneService extends CloudflareService } return $this->_parent_entity; } - private function setParentEntity(mixed $parent_entity): void + private function setParentEntity(AccountEntity $parent_entity): void { $this->_parent_entity = $parent_entity; $auth_entity = $this->getAuthModel()->getEntityByPK(uid: $this->getParentEntity()->getParent()); @@ -161,7 +161,7 @@ class ZoneService extends CloudflareService public function expire(AccountEntity $parent_entity, ZoneEntity $entity): ZoneEntity { $this->setParentEntity($parent_entity); - $response = $this->getMySocket()->get("accounts/{$entity->getPK()}/registrar/{$entity->getTitle()}"); + $response = $this->getMySocket()->get("accounts/{$parent_entity->getPK()}/registrar/{$entity->getTitle()}"); $body = json_decode($response->getBody()); $formDatas = ['expire_date', $body->result->expires_at]; // log_message("debug", var_export($formDatas, true));