diff --git a/src/Queue/AMQPCreateInfo.php b/src/Queue/AMQPCreateInfo.php index 52cdf5f..e55f2a1 100644 --- a/src/Queue/AMQPCreateInfo.php +++ b/src/Queue/AMQPCreateInfo.php @@ -89,7 +89,7 @@ public function toArray(): array 'redial_timeout' => $this->redialTimeout, ]); - if (!empty($this->consumerId)) { + if ($this->consumerId !== null && $this->consumerId !== '') { $result['consumer_id'] = $this->consumerId; } diff --git a/src/Queue/SQSCreateInfo.php b/src/Queue/SQSCreateInfo.php index d6e4ddc..2f891f6 100644 --- a/src/Queue/SQSCreateInfo.php +++ b/src/Queue/SQSCreateInfo.php @@ -85,7 +85,7 @@ public function toArray(): array if ($this->tags !== []) { $result['tags'] = $this->tags; } - if (!empty($this->messageGroupId)) { + if ($this->messageGroupId !== null && $this->messageGroupId !== '') { $result['message_group_id'] = $this->messageGroupId; }