Composer-Preload icon indicating copy to clipboard operation
Composer-Preload copied to clipboard

Fix getIterator must be compatible with interface

Open hultberg opened this issue 4 years ago • 0 comments

Deprecation notice in php 8.1:

Deprecation Notice: Return type of Ayesh\ComposerPreload\PreloadList::getIterator(): iterable should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /tmp/php/build/hbw/vendor/ayesh/composer-preload/src/PreloadList.php:19

I saw no reason to use the attribute to suppress the notice than to fix it since this class is final.

hultberg avatar Feb 27 '22 12:02 hultberg