From 517bd5a9099f534e2c6402cc9abe8696df0c01d0 Mon Sep 17 00:00:00 2001 From: tschuettler Date: Thu, 17 Mar 2022 17:14:41 +0100 Subject: [PATCH] [NFC] - Compatibility for PHP-7.4/PHP-8 There are a few more leftovers under vendor and packages: `find . -name "*.php" -exec php -l {} \; | grep -v "No"`. Not sure how to deal with that. --- Civi/Core/Event/EventPrinter.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Civi/Core/Event/EventPrinter.php b/Civi/Core/Event/EventPrinter.php index 0c2cfb6235..74091efd1d 100644 --- a/Civi/Core/Event/EventPrinter.php +++ b/Civi/Core/Event/EventPrinter.php @@ -18,7 +18,7 @@ class EventPrinter { */ public static function formatName($callback): string { $normalizeNamespace = function($symbol) { - return $symbol{0} === '\\' ? substr($symbol, 1) : $symbol; + return $symbol[0] === '\\' ? substr($symbol, 1) : $symbol; }; if (is_array($callback)) { [$a, $b] = $callback; -- 2.25.1