Code Duplication    Length = 6-6 lines in 2 locations

ecrire/req/sqlite_generique.php 1 location

@@ 1076-1081 (lines=6) @@
1073
	$set = array();
1074
	foreach ($champs as $champ => $val)
1075
		$set[] = $champ . "=$val";
1076
	if (!empty($set))
1077
		return spip_sqlite_query(
1078
			  _sqlite_calculer_expression('UPDATE', $table, ',')
1079
			. _sqlite_calculer_expression('SET', $set, ',')
1080
			. _sqlite_calculer_expression('WHERE', $where), 
1081
			$serveur, $requeter);
1082
}
1083
1084

ecrire/req/mysql.php 1 location

@@ 1163-1168 (lines=6) @@
1160
	$set = array();
1161
	foreach ($champs as $champ => $val)
1162
		$set[] = $champ . "=$val";
1163
	if (!empty($set))
1164
		return spip_mysql_query(
1165
			  calculer_mysql_expression('UPDATE', $table, ',')
1166
			. calculer_mysql_expression('SET', $set, ',')
1167
			. calculer_mysql_expression('WHERE', $where), 
1168
			$serveur, $requeter);
1169
}
1170
1171
/**