Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #32 from Steven-Oddineer/master

[security] Fixed a issue where hundreds of Warning "first argument of wpdb::prepare should have a placeholder" are displayed while define('WP_DEBUG', true);
  • Loading branch information...
commit 7b328bfef9e5f6ec4b8a40bd765481effcba0dde 2 parents b03231d + 3bfd7d8
@mvied authored
Showing with 3 additions and 3 deletions.
  1. +2 −2 lib/WordPressHTTPS.php
  2. +1 −1  uninstall.php
View
4 lib/WordPressHTTPS.php
@@ -196,7 +196,7 @@ public function getLocalDomains() {
);
if ( is_multisite() && is_subdomain_install() ) {
- $multisite_hosts = $wpdb->get_col($wpdb->prepare("SELECT domain FROM " . $wpdb->blogs, NULL));
+ $multisite_hosts = $wpdb->get_col($wpdb->prepare("SELECT domain FROM %d", $wpdb->blogs));
$hosts = array_merge($hosts, $multisite_hosts);
}
@@ -239,7 +239,7 @@ public function install() {
global $wpdb;
if ( is_multisite() && is_network_admin() ) {
- $blogs = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM " . $wpdb->blogs, NULL));
+ $blogs = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM %d", $wpdb->blogs));
} else {
$blogs = array($wpdb->blogid);
}
View
2  uninstall.php
@@ -30,7 +30,7 @@
global $wpdb;
if ( is_multisite() && is_network_admin() ) {
- $blogs = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM " . $wpdb->blogs, NULL));
+ $blogs = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM %d", $wpdb->blogs));
} else {
$blogs = array($wpdb->blogid);
}
Please sign in to comment.
Something went wrong with that request. Please try again.