From a53f1fdc4626fc2de4c177acf892e3ca4a05ba69 Mon Sep 17 00:00:00 2001 From: Yuri Kuznetsov Date: Fri, 19 Sep 2025 17:43:27 +0300 Subject: [PATCH] cleanup --- application/Espo/Core/Api/RequestWrapper.php | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/application/Espo/Core/Api/RequestWrapper.php b/application/Espo/Core/Api/RequestWrapper.php index db69c5172d..136952e934 100644 --- a/application/Espo/Core/Api/RequestWrapper.php +++ b/application/Espo/Core/Api/RequestWrapper.php @@ -267,32 +267,26 @@ class RequestWrapper implements ApiRequest public function isGet(): bool { - return $this->getMethod() === 'GET'; + return $this->getMethod() === Method::GET; } public function isPut(): bool { - return $this->getMethod() === 'PUT'; - } - - /** @noinspection PhpUnused */ - public function isUpdate(): bool - { - return $this->getMethod() === 'UPDATE'; + return $this->getMethod() === Method::PUT; } public function isPost(): bool { - return $this->getMethod() === 'POST'; + return $this->getMethod() === Method::POST; } public function isPatch(): bool { - return $this->getMethod() === 'PATCH'; + return $this->getMethod() === Method::PATCH; } public function isDelete(): bool { - return $this->getMethod() === 'DELETE'; + return $this->getMethod() === Method::DELETE; } }