<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[43630] trunk: Upgrade/Install: Fix coding standard errors after [43629].</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { white-space: pre-line; overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta" style="font-size: 105%">
<dt style="float: left; width: 6em; font-weight: bold">Revision</dt> <dd><a style="font-weight: bold" href="https://core.trac.wordpress.org/changeset/43630">43630</a><script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","description":"Review this Commit","action":{"@type":"ViewAction","url":"https://core.trac.wordpress.org/changeset/43630","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>flixos90</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2018-09-05 12:49:29 +0000 (Wed, 05 Sep 2018)</dd>
</dl>
<pre style='padding-left: 1em; margin: 2em 0; border-left: 2px solid #ccc; line-height: 1.25; font-size: 105%; font-family: sans-serif'>Upgrade/Install: Fix coding standard errors after <a href="https://core.trac.wordpress.org/changeset/43629">[43629]</a>.
See <a href="https://core.trac.wordpress.org/ticket/44896">#44896</a>.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunksrcwpadminincludesschemaphp">trunk/src/wp-admin/includes/schema.php</a></li>
<li><a href="#trunktestsphpunittestsadminincludesSchemaphp">trunk/tests/phpunit/tests/admin/includesSchema.php</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpadminincludesschemaphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/schema.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/schema.php 2018-09-05 11:01:36 UTC (rev 43629)
+++ trunk/src/wp-admin/includes/schema.php 2018-09-05 12:49:29 UTC (rev 43630)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -54,13 +54,13 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Blog specific tables.
</span><span class="cx" style="display: block; padding: 0 10px"> $blog_tables = "CREATE TABLE $wpdb->termmeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- meta_id bigint(20) unsigned NOT NULL auto_increment,
- term_id bigint(20) unsigned NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (meta_id),
- KEY term_id (term_id),
- KEY meta_key (meta_key($max_index_length))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ meta_id bigint(20) unsigned NOT NULL auto_increment,
+ term_id bigint(20) unsigned NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (meta_id),
+ KEY term_id (term_id),
+ KEY meta_key (meta_key($max_index_length))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->terms (
</span><span class="cx" style="display: block; padding: 0 10px"> term_id bigint(20) unsigned NOT NULL auto_increment,
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -90,149 +90,149 @@
</span><span class="cx" style="display: block; padding: 0 10px"> KEY term_taxonomy_id (term_taxonomy_id)
</span><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->commentmeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- meta_id bigint(20) unsigned NOT NULL auto_increment,
- comment_id bigint(20) unsigned NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (meta_id),
- KEY comment_id (comment_id),
- KEY meta_key (meta_key($max_index_length))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ meta_id bigint(20) unsigned NOT NULL auto_increment,
+ comment_id bigint(20) unsigned NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (meta_id),
+ KEY comment_id (comment_id),
+ KEY meta_key (meta_key($max_index_length))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->comments (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- comment_ID bigint(20) unsigned NOT NULL auto_increment,
- comment_post_ID bigint(20) unsigned NOT NULL default '0',
- comment_author tinytext NOT NULL,
- comment_author_email varchar(100) NOT NULL default '',
- comment_author_url varchar(200) NOT NULL default '',
- comment_author_IP varchar(100) NOT NULL default '',
- comment_date datetime NOT NULL default '0000-00-00 00:00:00',
- comment_date_gmt datetime NOT NULL default '0000-00-00 00:00:00',
- comment_content text NOT NULL,
- comment_karma int(11) NOT NULL default '0',
- comment_approved varchar(20) NOT NULL default '1',
- comment_agent varchar(255) NOT NULL default '',
- comment_type varchar(20) NOT NULL default '',
- comment_parent bigint(20) unsigned NOT NULL default '0',
- user_id bigint(20) unsigned NOT NULL default '0',
- PRIMARY KEY (comment_ID),
- KEY comment_post_ID (comment_post_ID),
- KEY comment_approved_date_gmt (comment_approved,comment_date_gmt),
- KEY comment_date_gmt (comment_date_gmt),
- KEY comment_parent (comment_parent),
- KEY comment_author_email (comment_author_email(10))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ comment_ID bigint(20) unsigned NOT NULL auto_increment,
+ comment_post_ID bigint(20) unsigned NOT NULL default '0',
+ comment_author tinytext NOT NULL,
+ comment_author_email varchar(100) NOT NULL default '',
+ comment_author_url varchar(200) NOT NULL default '',
+ comment_author_IP varchar(100) NOT NULL default '',
+ comment_date datetime NOT NULL default '0000-00-00 00:00:00',
+ comment_date_gmt datetime NOT NULL default '0000-00-00 00:00:00',
+ comment_content text NOT NULL,
+ comment_karma int(11) NOT NULL default '0',
+ comment_approved varchar(20) NOT NULL default '1',
+ comment_agent varchar(255) NOT NULL default '',
+ comment_type varchar(20) NOT NULL default '',
+ comment_parent bigint(20) unsigned NOT NULL default '0',
+ user_id bigint(20) unsigned NOT NULL default '0',
+ PRIMARY KEY (comment_ID),
+ KEY comment_post_ID (comment_post_ID),
+ KEY comment_approved_date_gmt (comment_approved,comment_date_gmt),
+ KEY comment_date_gmt (comment_date_gmt),
+ KEY comment_parent (comment_parent),
+ KEY comment_author_email (comment_author_email(10))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->links (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- link_id bigint(20) unsigned NOT NULL auto_increment,
- link_url varchar(255) NOT NULL default '',
- link_name varchar(255) NOT NULL default '',
- link_image varchar(255) NOT NULL default '',
- link_target varchar(25) NOT NULL default '',
- link_description varchar(255) NOT NULL default '',
- link_visible varchar(20) NOT NULL default 'Y',
- link_owner bigint(20) unsigned NOT NULL default '1',
- link_rating int(11) NOT NULL default '0',
- link_updated datetime NOT NULL default '0000-00-00 00:00:00',
- link_rel varchar(255) NOT NULL default '',
- link_notes mediumtext NOT NULL,
- link_rss varchar(255) NOT NULL default '',
- PRIMARY KEY (link_id),
- KEY link_visible (link_visible)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ link_id bigint(20) unsigned NOT NULL auto_increment,
+ link_url varchar(255) NOT NULL default '',
+ link_name varchar(255) NOT NULL default '',
+ link_image varchar(255) NOT NULL default '',
+ link_target varchar(25) NOT NULL default '',
+ link_description varchar(255) NOT NULL default '',
+ link_visible varchar(20) NOT NULL default 'Y',
+ link_owner bigint(20) unsigned NOT NULL default '1',
+ link_rating int(11) NOT NULL default '0',
+ link_updated datetime NOT NULL default '0000-00-00 00:00:00',
+ link_rel varchar(255) NOT NULL default '',
+ link_notes mediumtext NOT NULL,
+ link_rss varchar(255) NOT NULL default '',
+ PRIMARY KEY (link_id),
+ KEY link_visible (link_visible)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->options (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- option_id bigint(20) unsigned NOT NULL auto_increment,
- option_name varchar(191) NOT NULL default '',
- option_value longtext NOT NULL,
- autoload varchar(20) NOT NULL default 'yes',
- PRIMARY KEY (option_id),
- UNIQUE KEY option_name (option_name)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ option_id bigint(20) unsigned NOT NULL auto_increment,
+ option_name varchar(191) NOT NULL default '',
+ option_value longtext NOT NULL,
+ autoload varchar(20) NOT NULL default 'yes',
+ PRIMARY KEY (option_id),
+ UNIQUE KEY option_name (option_name)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->postmeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- meta_id bigint(20) unsigned NOT NULL auto_increment,
- post_id bigint(20) unsigned NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (meta_id),
- KEY post_id (post_id),
- KEY meta_key (meta_key($max_index_length))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ meta_id bigint(20) unsigned NOT NULL auto_increment,
+ post_id bigint(20) unsigned NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (meta_id),
+ KEY post_id (post_id),
+ KEY meta_key (meta_key($max_index_length))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->posts (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- ID bigint(20) unsigned NOT NULL auto_increment,
- post_author bigint(20) unsigned NOT NULL default '0',
- post_date datetime NOT NULL default '0000-00-00 00:00:00',
- post_date_gmt datetime NOT NULL default '0000-00-00 00:00:00',
- post_content longtext NOT NULL,
- post_title text NOT NULL,
- post_excerpt text NOT NULL,
- post_status varchar(20) NOT NULL default 'publish',
- comment_status varchar(20) NOT NULL default 'open',
- ping_status varchar(20) NOT NULL default 'open',
- post_password varchar(255) NOT NULL default '',
- post_name varchar(200) NOT NULL default '',
- to_ping text NOT NULL,
- pinged text NOT NULL,
- post_modified datetime NOT NULL default '0000-00-00 00:00:00',
- post_modified_gmt datetime NOT NULL default '0000-00-00 00:00:00',
- post_content_filtered longtext NOT NULL,
- post_parent bigint(20) unsigned NOT NULL default '0',
- guid varchar(255) NOT NULL default '',
- menu_order int(11) NOT NULL default '0',
- post_type varchar(20) NOT NULL default 'post',
- post_mime_type varchar(100) NOT NULL default '',
- comment_count bigint(20) NOT NULL default '0',
- PRIMARY KEY (ID),
- KEY post_name (post_name($max_index_length)),
- KEY type_status_date (post_type,post_status,post_date,ID),
- KEY post_parent (post_parent),
- KEY post_author (post_author)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ ID bigint(20) unsigned NOT NULL auto_increment,
+ post_author bigint(20) unsigned NOT NULL default '0',
+ post_date datetime NOT NULL default '0000-00-00 00:00:00',
+ post_date_gmt datetime NOT NULL default '0000-00-00 00:00:00',
+ post_content longtext NOT NULL,
+ post_title text NOT NULL,
+ post_excerpt text NOT NULL,
+ post_status varchar(20) NOT NULL default 'publish',
+ comment_status varchar(20) NOT NULL default 'open',
+ ping_status varchar(20) NOT NULL default 'open',
+ post_password varchar(255) NOT NULL default '',
+ post_name varchar(200) NOT NULL default '',
+ to_ping text NOT NULL,
+ pinged text NOT NULL,
+ post_modified datetime NOT NULL default '0000-00-00 00:00:00',
+ post_modified_gmt datetime NOT NULL default '0000-00-00 00:00:00',
+ post_content_filtered longtext NOT NULL,
+ post_parent bigint(20) unsigned NOT NULL default '0',
+ guid varchar(255) NOT NULL default '',
+ menu_order int(11) NOT NULL default '0',
+ post_type varchar(20) NOT NULL default 'post',
+ post_mime_type varchar(100) NOT NULL default '',
+ comment_count bigint(20) NOT NULL default '0',
+ PRIMARY KEY (ID),
+ KEY post_name (post_name($max_index_length)),
+ KEY type_status_date (post_type,post_status,post_date,ID),
+ KEY post_parent (post_parent),
+ KEY post_author (post_author)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;\n";
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Single site users table. The multisite flavor of the users table is handled below.
</span><span class="cx" style="display: block; padding: 0 10px"> $users_single_table = "CREATE TABLE $wpdb->users (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- ID bigint(20) unsigned NOT NULL auto_increment,
- user_login varchar(60) NOT NULL default '',
- user_pass varchar(255) NOT NULL default '',
- user_nicename varchar(50) NOT NULL default '',
- user_email varchar(100) NOT NULL default '',
- user_url varchar(100) NOT NULL default '',
- user_registered datetime NOT NULL default '0000-00-00 00:00:00',
- user_activation_key varchar(255) NOT NULL default '',
- user_status int(11) NOT NULL default '0',
- display_name varchar(250) NOT NULL default '',
- PRIMARY KEY (ID),
- KEY user_login_key (user_login),
- KEY user_nicename (user_nicename),
- KEY user_email (user_email)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ ID bigint(20) unsigned NOT NULL auto_increment,
+ user_login varchar(60) NOT NULL default '',
+ user_pass varchar(255) NOT NULL default '',
+ user_nicename varchar(50) NOT NULL default '',
+ user_email varchar(100) NOT NULL default '',
+ user_url varchar(100) NOT NULL default '',
+ user_registered datetime NOT NULL default '0000-00-00 00:00:00',
+ user_activation_key varchar(255) NOT NULL default '',
+ user_status int(11) NOT NULL default '0',
+ display_name varchar(250) NOT NULL default '',
+ PRIMARY KEY (ID),
+ KEY user_login_key (user_login),
+ KEY user_nicename (user_nicename),
+ KEY user_email (user_email)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;\n";
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Multisite users table
</span><span class="cx" style="display: block; padding: 0 10px"> $users_multi_table = "CREATE TABLE $wpdb->users (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- ID bigint(20) unsigned NOT NULL auto_increment,
- user_login varchar(60) NOT NULL default '',
- user_pass varchar(255) NOT NULL default '',
- user_nicename varchar(50) NOT NULL default '',
- user_email varchar(100) NOT NULL default '',
- user_url varchar(100) NOT NULL default '',
- user_registered datetime NOT NULL default '0000-00-00 00:00:00',
- user_activation_key varchar(255) NOT NULL default '',
- user_status int(11) NOT NULL default '0',
- display_name varchar(250) NOT NULL default '',
- spam tinyint(2) NOT NULL default '0',
- deleted tinyint(2) NOT NULL default '0',
- PRIMARY KEY (ID),
- KEY user_login_key (user_login),
- KEY user_nicename (user_nicename),
- KEY user_email (user_email)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ ID bigint(20) unsigned NOT NULL auto_increment,
+ user_login varchar(60) NOT NULL default '',
+ user_pass varchar(255) NOT NULL default '',
+ user_nicename varchar(50) NOT NULL default '',
+ user_email varchar(100) NOT NULL default '',
+ user_url varchar(100) NOT NULL default '',
+ user_registered datetime NOT NULL default '0000-00-00 00:00:00',
+ user_activation_key varchar(255) NOT NULL default '',
+ user_status int(11) NOT NULL default '0',
+ display_name varchar(250) NOT NULL default '',
+ spam tinyint(2) NOT NULL default '0',
+ deleted tinyint(2) NOT NULL default '0',
+ PRIMARY KEY (ID),
+ KEY user_login_key (user_login),
+ KEY user_nicename (user_nicename),
+ KEY user_email (user_email)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;\n";
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Usermeta.
</span><span class="cx" style="display: block; padding: 0 10px"> $usermeta_table = "CREATE TABLE $wpdb->usermeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- umeta_id bigint(20) unsigned NOT NULL auto_increment,
- user_id bigint(20) unsigned NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (umeta_id),
- KEY user_id (user_id),
- KEY meta_key (meta_key($max_index_length))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ umeta_id bigint(20) unsigned NOT NULL auto_increment,
+ user_id bigint(20) unsigned NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (umeta_id),
+ KEY user_id (user_id),
+ KEY meta_key (meta_key($max_index_length))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;\n";
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Global tables
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -244,80 +244,80 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Multisite global tables.
</span><span class="cx" style="display: block; padding: 0 10px"> $ms_global_tables = "CREATE TABLE $wpdb->blogs (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- blog_id bigint(20) NOT NULL auto_increment,
- site_id bigint(20) NOT NULL default '0',
- domain varchar(200) NOT NULL default '',
- path varchar(100) NOT NULL default '',
- registered datetime NOT NULL default '0000-00-00 00:00:00',
- last_updated datetime NOT NULL default '0000-00-00 00:00:00',
- public tinyint(2) NOT NULL default '1',
- archived tinyint(2) NOT NULL default '0',
- mature tinyint(2) NOT NULL default '0',
- spam tinyint(2) NOT NULL default '0',
- deleted tinyint(2) NOT NULL default '0',
- lang_id int(11) NOT NULL default '0',
- PRIMARY KEY (blog_id),
- KEY domain (domain(50),path(5)),
- KEY lang_id (lang_id)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ blog_id bigint(20) NOT NULL auto_increment,
+ site_id bigint(20) NOT NULL default '0',
+ domain varchar(200) NOT NULL default '',
+ path varchar(100) NOT NULL default '',
+ registered datetime NOT NULL default '0000-00-00 00:00:00',
+ last_updated datetime NOT NULL default '0000-00-00 00:00:00',
+ public tinyint(2) NOT NULL default '1',
+ archived tinyint(2) NOT NULL default '0',
+ mature tinyint(2) NOT NULL default '0',
+ spam tinyint(2) NOT NULL default '0',
+ deleted tinyint(2) NOT NULL default '0',
+ lang_id int(11) NOT NULL default '0',
+ PRIMARY KEY (blog_id),
+ KEY domain (domain(50),path(5)),
+ KEY lang_id (lang_id)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->blog_versions (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- blog_id bigint(20) NOT NULL default '0',
- db_version varchar(20) NOT NULL default '',
- last_updated datetime NOT NULL default '0000-00-00 00:00:00',
- PRIMARY KEY (blog_id),
- KEY db_version (db_version)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ blog_id bigint(20) NOT NULL default '0',
+ db_version varchar(20) NOT NULL default '',
+ last_updated datetime NOT NULL default '0000-00-00 00:00:00',
+ PRIMARY KEY (blog_id),
+ KEY db_version (db_version)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->blogmeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- meta_id bigint(20) unsigned NOT NULL auto_increment,
- blog_id bigint(20) NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (meta_id),
- KEY meta_key (meta_key($max_index_length)),
- KEY blog_id (blog_id)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ meta_id bigint(20) unsigned NOT NULL auto_increment,
+ blog_id bigint(20) NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (meta_id),
+ KEY meta_key (meta_key($max_index_length)),
+ KEY blog_id (blog_id)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->registration_log (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- ID bigint(20) NOT NULL auto_increment,
- email varchar(255) NOT NULL default '',
- IP varchar(30) NOT NULL default '',
- blog_id bigint(20) NOT NULL default '0',
- date_registered datetime NOT NULL default '0000-00-00 00:00:00',
- PRIMARY KEY (ID),
- KEY IP (IP)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ ID bigint(20) NOT NULL auto_increment,
+ email varchar(255) NOT NULL default '',
+ IP varchar(30) NOT NULL default '',
+ blog_id bigint(20) NOT NULL default '0',
+ date_registered datetime NOT NULL default '0000-00-00 00:00:00',
+ PRIMARY KEY (ID),
+ KEY IP (IP)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->site (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- id bigint(20) NOT NULL auto_increment,
- domain varchar(200) NOT NULL default '',
- path varchar(100) NOT NULL default '',
- PRIMARY KEY (id),
- KEY domain (domain(140),path(51))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ id bigint(20) NOT NULL auto_increment,
+ domain varchar(200) NOT NULL default '',
+ path varchar(100) NOT NULL default '',
+ PRIMARY KEY (id),
+ KEY domain (domain(140),path(51))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->sitemeta (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- meta_id bigint(20) NOT NULL auto_increment,
- site_id bigint(20) NOT NULL default '0',
- meta_key varchar(255) default NULL,
- meta_value longtext,
- PRIMARY KEY (meta_id),
- KEY meta_key (meta_key($max_index_length)),
- KEY site_id (site_id)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ meta_id bigint(20) NOT NULL auto_increment,
+ site_id bigint(20) NOT NULL default '0',
+ meta_key varchar(255) default NULL,
+ meta_value longtext,
+ PRIMARY KEY (meta_id),
+ KEY meta_key (meta_key($max_index_length)),
+ KEY site_id (site_id)
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;
</span><span class="cx" style="display: block; padding: 0 10px"> CREATE TABLE $wpdb->signups (
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- signup_id bigint(20) NOT NULL auto_increment,
- domain varchar(200) NOT NULL default '',
- path varchar(100) NOT NULL default '',
- title longtext NOT NULL,
- user_login varchar(60) NOT NULL default '',
- user_email varchar(100) NOT NULL default '',
- registered datetime NOT NULL default '0000-00-00 00:00:00',
- activated datetime NOT NULL default '0000-00-00 00:00:00',
- active tinyint(1) NOT NULL default '0',
- activation_key varchar(50) NOT NULL default '',
- meta longtext,
- PRIMARY KEY (signup_id),
- KEY activation_key (activation_key),
- KEY user_email (user_email),
- KEY user_login_email (user_login,user_email),
- KEY domain_path (domain(140),path(51))
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ signup_id bigint(20) NOT NULL auto_increment,
+ domain varchar(200) NOT NULL default '',
+ path varchar(100) NOT NULL default '',
+ title longtext NOT NULL,
+ user_login varchar(60) NOT NULL default '',
+ user_email varchar(100) NOT NULL default '',
+ registered datetime NOT NULL default '0000-00-00 00:00:00',
+ activated datetime NOT NULL default '0000-00-00 00:00:00',
+ active tinyint(1) NOT NULL default '0',
+ activation_key varchar(50) NOT NULL default '',
+ meta longtext,
+ PRIMARY KEY (signup_id),
+ KEY activation_key (activation_key),
+ KEY user_email (user_email),
+ KEY user_login_email (user_login,user_email),
+ KEY domain_path (domain(140),path(51))
</ins><span class="cx" style="display: block; padding: 0 10px"> ) $charset_collate;";
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> switch ( $scope ) {
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -563,7 +563,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $fat_options = array( 'moderation_keys', 'recently_edited', 'blacklist_keys', 'uninstall_plugins' );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $keys = "'" . implode( "', '", array_keys( $options ) ) . "'";
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $existing_options = $wpdb->get_col( "SELECT option_name FROM $wpdb->options WHERE option_name in ( $keys )" ); // phpcs:ignore WordPress.WP.PreparedSQL.NotPrepared
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $existing_options = $wpdb->get_col( "SELECT option_name FROM $wpdb->options WHERE option_name in ( $keys )" ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $insert = '';
</span><span class="cx" style="display: block; padding: 0 10px"> foreach ( $options as $option => $value ) {
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -586,7 +586,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( ! empty( $insert ) ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $wpdb->query( "INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES " . $insert ); // phpcs:ignore WordPress.WP.PreparedSQL.NotPrepared
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $wpdb->query( "INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES " . $insert ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // In case it is set, but blank, update "home".
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1206,7 +1206,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> --The Team @ SITE_NAME'
</span><span class="cx" style="display: block; padding: 0 10px"> );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $misc_exts = array(
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $misc_exts = array(
</ins><span class="cx" style="display: block; padding: 0 10px"> // Images.
</span><span class="cx" style="display: block; padding: 0 10px"> 'jpg',
</span><span class="cx" style="display: block; padding: 0 10px"> 'jpeg',
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1290,7 +1290,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> $insert .= $wpdb->prepare( '( %d, %s, %s)', $network_id, $meta_key, $meta_value );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $wpdb->query( "INSERT INTO $wpdb->sitemeta ( site_id, meta_key, meta_value ) VALUES " . $insert ); // phpcs:ignore WordPress.WP.PreparedSQL.NotPrepared
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $wpdb->query( "INSERT INTO $wpdb->sitemeta ( site_id, meta_key, meta_value ) VALUES " . $insert ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> /**
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1327,7 +1327,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $insert .= $wpdb->prepare( '( %d, %s, %s)', $site_id, $meta_key, $meta_value );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $wpdb->query( "INSERT INTO $wpdb->blogmeta ( blog_id, meta_key, meta_value ) VALUES " . $insert ); // phpcs:ignore WordPress.WP.PreparedSQL.NotPrepared
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $wpdb->query( "INSERT INTO $wpdb->blogmeta ( blog_id, meta_key, meta_value ) VALUES " . $insert ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> wp_cache_set( 'last_changed', microtime(), 'sites' );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span></span></pre></div>
<a id="trunktestsphpunittestsadminincludesSchemaphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/tests/phpunit/tests/admin/includesSchema.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/tests/phpunit/tests/admin/includesSchema.php 2018-09-05 11:01:36 UTC (rev 43629)
+++ trunk/tests/phpunit/tests/admin/includesSchema.php 2018-09-05 12:49:29 UTC (rev 43630)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1,5 +1,5 @@
</span><span class="cx" style="display: block; padding: 0 10px"> <?php
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-// phpcs:ignoreFile WordPress.WP.PreparedSQL.NotPrepared
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+// phpcs:ignoreFile WordPress.DB.PreparedSQL.NotPrepared
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> /**
</span><span class="cx" style="display: block; padding: 0 10px"> * @group admin
</span></span></pre>
</div>
</div>
</body>
</html>