From 007b35d8f7ed21cab9aa47406578ae02f73f91c5 Mon Sep 17 00:00:00 2001 From: Eric Norris Date: Fri, 12 Jun 2020 14:56:55 -0400 Subject: [PATCH] fix: PHP 7.4 Compatibility Fix (#259) - fixes `Deprecated: Array and string offset access syntax with curly braces is deprecated in...` --- src/Trace/Propagator/CloudTraceFormatter.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Trace/Propagator/CloudTraceFormatter.php b/src/Trace/Propagator/CloudTraceFormatter.php index ad5e29124..382c0c978 100644 --- a/src/Trace/Propagator/CloudTraceFormatter.php +++ b/src/Trace/Propagator/CloudTraceFormatter.php @@ -101,7 +101,7 @@ private function baseConvert($numstring, $fromBase, $toBase) $result = ''; for ($i = 0; $i < $length; $i++) { - $number[$i] = strpos($chars, $numstring{$i}); + $number[$i] = strpos($chars, $numstring[$i]); } do { @@ -117,7 +117,7 @@ private function baseConvert($numstring, $fromBase, $toBase) } } $length = $newlen; - $result = $newstring{$divide} . $result; + $result = $newstring[$divide] . $result; } while ($newlen != 0); return $result;