Avoid PHP Warning: count(): Parameter must be an array or an object that implements Countable
|Assignee:||José Raddaoui Marín||% Done:|
|Google Code Legacy ID:||Tested version:|
In PHP 7.2, count() will throw a warning on invalid countable types:
We should try to avoid that warning as it may lead to unexpected issues in the future. For example (the latest count in):
#1 Updated by José Raddaoui Marín over 2 years ago
See https://stackoverflow.com/questions/49662029/count-emitting-an-e-warning for more info on why this could be a problem and possible solutions.