Ticket #8014: 8014.002.2.diff
| File 8014.002.2.diff, 920 bytes (added by aaroncampbell, 3 years ago) |
|---|
-
trunk/wp-admin/includes/upgrade.php
1185 1185 // Create a tablename index for an array ($cqueries) of queries 1186 1186 foreach($queries as $qry) { 1187 1187 if(preg_match("|CREATE TABLE ([^ ]*)|", $qry, $matches)) { 1188 $cqueries[ strtolower($matches[1])] = $qry;1188 $cqueries[trim( strtolower($matches[1]), '`' )] = $qry; 1189 1189 $for_update[$matches[1]] = 'Created table '.$matches[1]; 1190 1190 } 1191 1191 else if(preg_match("|CREATE DATABASE ([^ ]*)|", $qry, $matches)) { … … 1224 1224 foreach($flds as $fld) { 1225 1225 // Extract the field name 1226 1226 preg_match("|^([^ ]*)|", trim($fld), $fvals); 1227 $fieldname = $fvals[1];1227 $fieldname = trim( $fvals[1], '`' ); 1228 1228 1229 1229 // Verify the found field name 1230 1230 $validfield = true;
