Page 1 of 1

Warning: count(): Parameter in DesignManager.module.php

Posted: Thu Sep 26, 2019 4:20 pm
by moonie
Whenever an Editor without permission of "Manage Designs" logs in, this warning appears on the welcome screen:

Code: Select all

Warning: count(): Parameter must be an array or an object that implements Countable in .../modules/DesignManager/DesignManager.module.php on line 48
And it disappears after a reload.

If you give the Editors permission to Manage Designs there is no error present. Happened on 2.2.10 - 2.2.12

Re: Warning: count(): Parameter in DesignManager.module.php

Posted: Thu Sep 26, 2019 11:42 pm
by DIGI3
It's probably best to not display warnings to the screen, send them to your error log instead. For live sites, you can also set your error reporting level to not include warnings.

For your development site, warnings are good to pay attention to. In this case, my guess is you're using a newer version of PHP than is supported by your version of CMSMS (CMSMS 2.2.12 supports up to PHP 7.2. CMSMS 2.3 will support PHP 7.3).