debesha / DoctrineProfileExtraBundle

Bundle to get information about doctrine hydration performance
MIT License
123 stars 16 forks source link

php7.2 vs getSingleScalarResult #11

Closed index0h closed 6 years ago

index0h commented 6 years ago

Hi, php 7.2 triggers warning on call count or sizeof functions with not an array variable. When I load data with getSingleScalarResult - result will be not an array, stack trace:

sizeof(): Parameter must be an array or an object that implements Countable

/my_project/vendor/debesha/doctrine-hydration-profiler-bundle/ORM/LoggingHydratorTrait.php:56
/my_project/vendor/doctrine/orm/lib/Doctrine/ORM/AbstractQuery.php:971
/my_project/vendor/doctrine/orm/lib/Doctrine/ORM/AbstractQuery.php:917
/my_project/vendor/doctrine/orm/lib/Doctrine/ORM/AbstractQuery.php:797
/my_project/vendor/doctrine/orm/lib/Doctrine/ORM/AbstractQuery.php:826
...

Package versions: