From a5384b74665d8ffa714b8543b026069017dd91d5 Mon Sep 17 00:00:00 2001 From: Junade Date: Tue, 3 Oct 2017 17:59:59 +0100 Subject: [PATCH 1/2] Correct input types for (Bypass) Cache on Cookie --- src/Configurations/PageRulesActions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Configurations/PageRulesActions.php b/src/Configurations/PageRulesActions.php index de28b45..cdb03c8 100644 --- a/src/Configurations/PageRulesActions.php +++ b/src/Configurations/PageRulesActions.php @@ -40,7 +40,7 @@ class PageRulesActions implements Configurations ]); } - public function setBypassCacheOnCookie(bool $value) + public function setBypassCacheOnCookie(string $value) { if (preg_match('/^([a-zA-Z0-9\.=|_*-]+)$/i', $value) < 1) { throw new ConfigurationsException("Invalid cookie string."); @@ -76,7 +76,7 @@ class PageRulesActions implements Configurations ]); } - public function setCacheOnCookie(bool $value) + public function setCacheOnCookie(string $value) { if (preg_match('/^([a-zA-Z0-9\.=|_*-]+)$/i', $value) < 1) { throw new ConfigurationsException("Invalid cookie string."); From d49028a31ea97922f394188fc34c274a11886753 Mon Sep 17 00:00:00 2001 From: Junade Ali Date: Tue, 3 Oct 2017 18:09:07 +0100 Subject: [PATCH 2/2] Updated DNSTest style. --- tests/Endpoints/DNSTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/Endpoints/DNSTest.php b/tests/Endpoints/DNSTest.php index 3035b5b..66eb9d9 100644 --- a/tests/Endpoints/DNSTest.php +++ b/tests/Endpoints/DNSTest.php @@ -93,13 +93,13 @@ class DNSTest extends TestCase $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); $mock->method('put')->willReturn($response); - $details = array( + $details = [ 'type' => 'A', 'name' => "example.com", 'content' => "1.2.3.4", 'ttl' => 120, 'proxied' => false, - ); + ]; $mock->expects($this->once()) ->method('put')