X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fcore%2Flib%2FDrupal%2FCore%2FDatabase%2FDriver%2Fmysql%2FUpsert.php;fp=web%2Fcore%2Flib%2FDrupal%2FCore%2FDatabase%2FDriver%2Fmysql%2FUpsert.php;h=8eda775c0a7469da1cd9084b79fa6b3fa02da056;hp=6c1af1e812a6641ffaa2098c8477c38514aead2f;hb=0bf8d09d2542548982e81a441b1f16e75873a04f;hpb=74df008bdbb3a11eeea356744f39b802369bda3c diff --git a/web/core/lib/Drupal/Core/Database/Driver/mysql/Upsert.php b/web/core/lib/Drupal/Core/Database/Driver/mysql/Upsert.php index 6c1af1e81..8eda775c0 100644 --- a/web/core/lib/Drupal/Core/Database/Driver/mysql/Upsert.php +++ b/web/core/lib/Drupal/Core/Database/Driver/mysql/Upsert.php @@ -18,6 +18,9 @@ class Upsert extends QueryUpsert { // Default fields are always placed first for consistency. $insert_fields = array_merge($this->defaultFields, $this->insertFields); + $insert_fields = array_map(function ($field) { + return $this->connection->escapeField($field); + }, $insert_fields); $query = $comments . 'INSERT INTO {' . $this->table . '} (' . implode(', ', $insert_fields) . ') VALUES ';