From 6d687135d4a9efb091f8873dfcfcbae1f35c60cc Mon Sep 17 00:00:00 2001 From: "Matthew M. Keeler" Date: Wed, 20 Sep 2023 11:43:04 -0400 Subject: [PATCH 1/2] chore: Update CODEOWNERS --- CODEOWNERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CODEOWNERS b/CODEOWNERS index 7d0dac3..0a84a49 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -1,2 +1,2 @@ # Repository Maintainers -* @launchdarkly/team-sdk +* @launchdarkly/team-sdk-php From 3b6284ed7eeb6aef8552d11163637f7b352fd0ec Mon Sep 17 00:00:00 2001 From: Matthew Keeler Date: Wed, 20 Sep 2023 15:53:42 -0400 Subject: [PATCH 2/2] Fix lint --- src/EvaluationContextConverter.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/EvaluationContextConverter.php b/src/EvaluationContextConverter.php index d3f374a..b838f8c 100644 --- a/src/EvaluationContextConverter.php +++ b/src/EvaluationContextConverter.php @@ -135,17 +135,14 @@ private function buildSingleContext(array $attributes, string $kind, string $key continue; } - // Validation for name if ($k === "name" && is_string($v)) { $builder->name($v); } elseif ($k === "name") { $this->logger->error("The attribute 'name' must be a string"); - // Validation for anonymous } elseif ($k === "anonymous" && is_bool($v)) { $builder->anonymous($v); } elseif ($k === "anonymous") { $this->logger->error("The attribute 'anonymous' must be a boolean"); - // Validation for privateAttributes } elseif ($k === "privateAttributes" && is_array($v)) { $privateAttributes = array_values($v); foreach ($privateAttributes as $privateAttribute) { @@ -158,8 +155,8 @@ private function buildSingleContext(array $attributes, string $kind, string $key } } elseif ($k === "privateAttributes") { $this->logger->error("'privateAttributes' in an evaluation context must be an array"); - // Catch all for remaining attributes } else { + // Catch all for remaining attributes $builder->set($k, $v); } }