Ticket #26106: 26106.2.diff
File 26106.2.diff, 621 bytes (added by , 11 years ago) |
---|
-
wp-includes/wp-db.php
1785 1785 $wheres[] = "`$field` = {$form}"; 1786 1786 } 1787 1787 1788 $sql = "UPDATE `$table` SET " . implode( ', ', $bits ) . ' WHERE ' . implode( ' AND ', $wheres ); 1788 $wheres = empty ( $where ) ? '1 = 1' : implode( ' AND ', $wheres ); 1789 1790 $sql = "UPDATE `$table` SET " . implode( ', ', $bits ) . ' WHERE ' . $wheres; 1789 1791 return $this->query( $this->prepare( $sql, array_merge( array_values( $data ), array_values( $where ) ) ) ); 1790 1792 } 1791 1793