Fix compatibility with old multicompany modules

This commit is contained in:
Laurent Destailleur 2019-08-29 00:19:46 +02:00
parent cb8bee7899
commit c10f755619

View File

@ -105,7 +105,7 @@ function setEntity($currentobject)
{ {
global $conf, $mc; global $conf, $mc;
if (is_object($mc)) if (is_object($mc) && method_exists($mc, 'setEntity'))
{ {
return $mc->setEntity($currentobject); return $mc->setEntity($currentobject);
} }