From e4f5b52d6a0a4ac0893828c68ec92aa19c8ca1f5 Mon Sep 17 00:00:00 2001 From: ilevyor <81260226+ilevyor@users.noreply.github.com> Date: Fri, 6 Aug 2021 14:01:30 -0400 Subject: [PATCH] php qol Sam asked for (#44) Co-authored-by: Itamar Levy-Or --- src/AWS/CRT/Internal/Encoding.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/AWS/CRT/Internal/Encoding.php b/src/AWS/CRT/Internal/Encoding.php index 7fc93f4..75446fc 100644 --- a/src/AWS/CRT/Internal/Encoding.php +++ b/src/AWS/CRT/Internal/Encoding.php @@ -29,6 +29,9 @@ final class Encoding { } public static function encodeString($str) { + if (is_array($str)) { + $str = $str[0]; + } return pack("Na*", strlen($str), $str); } }