Compatibilty php 7.2
This commit is contained in:
parent
aafc108260
commit
ed013c1b7e
@ -4142,7 +4142,7 @@ abstract class CommonObject
|
|||||||
*
|
*
|
||||||
* @param int $rowid Id of line. Use the id of object if not defined. Deprecated. Function must be called without parameters.
|
* @param int $rowid Id of line. Use the id of object if not defined. Deprecated. Function must be called without parameters.
|
||||||
* @param array $optionsArray Array resulting of call of extrafields->fetch_name_optionals_label(). Deprecated. Function must be called without parameters.
|
* @param array $optionsArray Array resulting of call of extrafields->fetch_name_optionals_label(). Deprecated. Function must be called without parameters.
|
||||||
* @return int <0 if error, 0 if no optionals to find nor found, 1 if a line is found and optional loaded
|
* @return int <0 if error, 0 if no values of extrafield to find nor found, 1 if an attribute is found and value loaded
|
||||||
*/
|
*/
|
||||||
function fetch_optionals($rowid=null,$optionsArray=null)
|
function fetch_optionals($rowid=null,$optionsArray=null)
|
||||||
{
|
{
|
||||||
@ -4176,7 +4176,7 @@ abstract class CommonObject
|
|||||||
if ($table_element == 'categorie') $table_element = 'categories'; // For compatibility
|
if ($table_element == 'categorie') $table_element = 'categories'; // For compatibility
|
||||||
|
|
||||||
// Request to get complementary values
|
// Request to get complementary values
|
||||||
if (count($optionsArray) > 0)
|
if (is_array($optionsArray) && count($optionsArray) > 0)
|
||||||
{
|
{
|
||||||
$sql = "SELECT rowid";
|
$sql = "SELECT rowid";
|
||||||
foreach ($optionsArray as $name => $label)
|
foreach ($optionsArray as $name => $label)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user