Jump to content
thirty bees forum
  • 0

PHP7 Countable Error in Customer Service Messages


DarkHorse

Question

The following error appeared while accessing Customer Service Messages in migration site:

Warning on line 402 in file controllers/admin/AdminCustomerThreadsController.php
[2] count(): Parameter must be an array or an object that implements Countable

The following fix at line 402 is required because the initial code checking the $errors array is in reverse order:

Original line:

if (count($errors) && is_array($errors)) {

Corrected line:

if (is_array($errors) && count($errors)) {

 

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...