From 84919d94d734a05bde16041ea743b90b36eb41cf Mon Sep 17 00:00:00 2001 From: The Digital Orchard Date: Sat, 27 Jul 2019 16:21:41 -0700 Subject: [PATCH] allow wildcard region; syntax fix with == instead of = --- src/Identity/v3/Models/Endpoint.php | 2 +- src/Identity/v3/Models/Service.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Identity/v3/Models/Endpoint.php b/src/Identity/v3/Models/Endpoint.php index 775768a4..2d85a9a7 100644 --- a/src/Identity/v3/Models/Endpoint.php +++ b/src/Identity/v3/Models/Endpoint.php @@ -80,7 +80,7 @@ public function delete() public function regionMatches(string $value): bool { - return $this->region && $this->region == $value; + return in_array($this->region, ['*', $value]); } public function interfaceMatches(string $value): bool diff --git a/src/Identity/v3/Models/Service.php b/src/Identity/v3/Models/Service.php index 6b58c088..61428436 100644 --- a/src/Identity/v3/Models/Service.php +++ b/src/Identity/v3/Models/Service.php @@ -93,7 +93,7 @@ private function nameMatches(string $value): bool private function typeMatches(string $value): bool { - return $this->type && $this->type = $value; + return $this->type && $this->type == $value; } /**