diff --git a/ISO4217Test.php b/ISO4217Test.php index 88291f3..eb992a3 100644 --- a/ISO4217Test.php +++ b/ISO4217Test.php @@ -140,7 +140,9 @@ private static function getCurrencies(string $indexedBy): array { $reflected = new \ReflectionClass('Alcohol\ISO4217'); $currencies = $reflected->getProperty('currencies'); - $currencies->setAccessible(true); + if (PHP_VERSION_ID < 80100) { + $currencies->setAccessible(true); + } $currencies = $currencies->getValue(new ISO4217()); return array_reduce(