Skip to content
Extraits de code Groupes Projets
Valider 7954d4c4 rédigé par mattab's avatar mattab
Parcourir les fichiers

when there's a fire, pour a lot of water over it!! fixes #6485

parent 7617ea31
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -640,10 +640,7 @@ class Row implements \ArrayAccess, \IteratorAggregate
return $newValue;
}
if (is_string($columnToSumValue)) {
throw new Exception("Trying to add two strings in DataTable\Row::sumRowArray: "
. "'$thisColumnValue' + '$columnToSumValue'" . " for row " . $this->__toString());
}
$this->warnWhenSummingTwoStrings($thisColumnValue, $columnToSumValue);
return 0;
}
......@@ -761,4 +758,16 @@ class Row implements \ArrayAccess, \IteratorAggregate
}
}
protected function warnWhenSummingTwoStrings($thisColumnValue, $columnToSumValue)
{
if (is_string($columnToSumValue)) {
Log::warning(
"Trying to add two strings in DataTable\Row::sumRowArray: %s + %s for row %s",
$thisColumnValue,
$columnToSumValue,
$this->__toString()
);
}
}
}
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter