Jump to content

memcached warning on ps1744 and php7.0


salvotnt

Recommended Posts

error log reporting a lot error about memcached system :

Quote

PHP Warning: in_array() expects parameter 2 to be array, boolean given in /home/dfgdfgaen/public_html/classes/cache/CacheMemcached.php on line 82

server Linux #1 SMP Sat Nov 30 02:18:52 EST 2019 x86_64

software  server: LiteSpeed

Version  PHP: 7.0.33

Limit of memory: 512M

execution time max: 300 sec

 

this warning occur alot in daily error logs...

Any idea for fix this ?

thanks and bye

 

Link to comment
Share on other sites

Find the following line from the function connect() (File: /clases/cache/CacheMemcached.php, Line 82)

$this->is_connected = in_array('255.255.255', $this->memcached->getVersion(), true) === false;

and replace it with


$this->is_connected = $this->memcached->getVersion() ? in_array('255.255.255', $memcached->getVersion(), true) === false : false;

  • Thanks 1
Link to comment
Share on other sites

  • 2 weeks later...
  • 7 months later...

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...