diff --git a/core/metamodel.class.php b/core/metamodel.class.php index f53967974..872c54008 100644 --- a/core/metamodel.class.php +++ b/core/metamodel.class.php @@ -5463,9 +5463,11 @@ abstract class MetaModel continue; // Ignore this non-scalar value } } - - $aSearches[] = '$'.$sSearch.'$'; - $aReplacements[] = (string) $replace; + else + { + $aSearches[] = '$'.$sSearch.'$'; + $aReplacements[] = (string) $replace; + } } return str_replace($aSearches, $aReplacements, $sInput); }