<!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>[56176] trunk/src/wp-admin/includes: Docs: Replace multiple single line comments with multi-line comments.</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/56176">56176</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/56176","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>audrasjb</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2023-07-09 20:05:43 +0000 (Sun, 09 Jul 2023)</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'>Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/<a href="https://core.trac.wordpress.org/ticket/5">#5</a>-inline-comments.
Follow-up to <a href="https://core.trac.wordpress.org/changeset/56174">[56174]</a>, <a href="https://core.trac.wordpress.org/changeset/56175">[56175]</a>.
Props costdev, audrasjb.
See <a href="https://core.trac.wordpress.org/ticket/58459">#58459</a>.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunksrcwpadminincludesmsphp">trunk/src/wp-admin/includes/ms.php</a></li>
<li><a href="#trunksrcwpadminincludesnavmenuphp">trunk/src/wp-admin/includes/nav-menu.php</a></li>
<li><a href="#trunksrcwpadminincludesoptionsphp">trunk/src/wp-admin/includes/options.php</a></li>
<li><a href="#trunksrcwpadminincludesplugininstallphp">trunk/src/wp-admin/includes/plugin-install.php</a></li>
<li><a href="#trunksrcwpadminincludespluginphp">trunk/src/wp-admin/includes/plugin.php</a></li>
<li><a href="#trunksrcwpadminincludespostphp">trunk/src/wp-admin/includes/post.php</a></li>
<li><a href="#trunksrcwpadminincludesrevisionphp">trunk/src/wp-admin/includes/revision.php</a></li>
<li><a href="#trunksrcwpadminincludesschemaphp">trunk/src/wp-admin/includes/schema.php</a></li>
<li><a href="#trunksrcwpadminincludestemplatephp">trunk/src/wp-admin/includes/template.php</a></li>
<li><a href="#trunksrcwpadminincludesupdatecorephp">trunk/src/wp-admin/includes/update-core.php</a></li>
<li><a href="#trunksrcwpadminincludesupgradephp">trunk/src/wp-admin/includes/upgrade.php</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpadminincludesmsphp"></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/ms.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/ms.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/ms.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1005,8 +1005,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> jQuery( function($) {
</span><span class="cx" style="display: block; padding: 0 10px"> var languageSelect = $( '#WPLANG' );
</span><span class="cx" style="display: block; padding: 0 10px"> $( 'form' ).on( 'submit', function() {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Don't show a spinner for English and installed languages,
- // as there is nothing to download.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Don't show a spinner for English and installed languages,
+ * as there is nothing to download.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! languageSelect.find( 'option:selected' ).data( 'installed' ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $( '#submit', this ).after( '<span class="spinner language-install-spinner is-active" />' );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span></span></pre></div>
<a id="trunksrcwpadminincludesnavmenuphp"></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/nav-menu.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/nav-menu.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/nav-menu.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1502,8 +1502,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( ! is_null( $data ) && $data ) {
</span><span class="cx" style="display: block; padding: 0 10px"> foreach ( $data as $post_input_data ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // For input names that are arrays (e.g. `menu-item-db-id[3][4][5]`),
- // derive the array path keys via regex and set the value in $_POST.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * For input names that are arrays (e.g. `menu-item-db-id[3][4][5]`),
+ * derive the array path keys via regex and set the value in $_POST.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> preg_match( '#([^\[]*)(\[(.+)\])?#', $post_input_data->name, $matches );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $array_bits = array( $matches[1] );
</span></span></pre></div>
<a id="trunksrcwpadminincludesoptionsphp"></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/options.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/options.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/options.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -90,8 +90,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> var languageSelect = $( '#WPLANG' );
</span><span class="cx" style="display: block; padding: 0 10px"> $( 'form' ).on( 'submit', function() {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Don't show a spinner for English and installed languages,
- // as there is nothing to download.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Don't show a spinner for English and installed languages,
+ * as there is nothing to download.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! languageSelect.find( 'option:selected' ).data( 'installed' ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $( '#submit', this ).after( '<span class="spinner language-install-spinner is-active" />' );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span></span></pre></div>
<a id="trunksrcwpadminincludesplugininstallphp"></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/plugin-install.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/plugin-install.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/plugin-install.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -486,8 +486,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> } else {
</span><span class="cx" style="display: block; padding: 0 10px"> $key = array_keys( $installed_plugin );
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Use the first plugin regardless of the name.
- // Could have issues for multiple plugins in one directory if they share different version numbers.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Use the first plugin regardless of the name.
+ * Could have issues for multiple plugins in one directory if they share different version numbers.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $key = reset( $key );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $update_file = $api->slug . '/' . $key;
</span></span></pre></div>
<a id="trunksrcwpadminincludespluginphp"></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/plugin.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/plugin.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/plugin.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -178,8 +178,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> 'title' => true,
</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">- // Name is marked up inside <a> tags. Don't allow these.
- // Author is too, but some plugins have used <a> here (omitting Author URI).
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Name is marked up inside <a> tags. Don't allow these.
+ * Author is too, but some plugins have used <a> here (omitting Author URI).
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $plugin_data['Name'] = wp_kses( $plugin_data['Name'], $allowed_tags_in_links );
</span><span class="cx" style="display: block; padding: 0 10px"> $plugin_data['Author'] = wp_kses( $plugin_data['Author'], $allowed_tags );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -969,8 +971,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $this_plugin_dir = trailingslashit( dirname( $plugins_dir . $plugin_file ) );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // If plugin is in its own directory, recursively delete the directory.
- // Base check on if plugin includes directory separator AND that it's not the root plugin folder.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * If plugin is in its own directory, recursively delete the directory.
+ * Base check on if plugin includes directory separator AND that it's not the root plugin folder.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( strpos( $plugin_file, '/' ) && $this_plugin_dir !== $plugins_dir ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $deleted = $wp_filesystem->delete( $this_plugin_dir, true );
</span><span class="cx" style="display: block; padding: 0 10px"> } else {
</span></span></pre></div>
<a id="trunksrcwpadminincludespostphp"></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/post.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/post.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/post.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -135,8 +135,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $published_statuses = array( 'publish', 'future' );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Posts 'submitted for approval' are submitted to $_POST the same as if they were being published.
- // Change status from 'publish' to 'pending' if user lacks permissions to publish or to resave published posts.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Posts 'submitted for approval' are submitted to $_POST the same as if they were being published.
+ * Change status from 'publish' to 'pending' if user lacks permissions to publish or to resave published posts.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( isset( $post_data['post_status'] )
</span><span class="cx" style="display: block; padding: 0 10px"> && ( in_array( $post_data['post_status'], $published_statuses, true )
</span><span class="cx" style="display: block; padding: 0 10px"> && ! current_user_can( $ptype->cap->publish_posts ) )
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1443,8 +1445,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $post->post_name = sanitize_title( $post->post_name ? $post->post_name : $post->post_title, $post->ID );
</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">- // If the user wants to set a new name -- override the current one.
- // Note: if empty name is supplied -- use the title instead, see #6072.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * If the user wants to set a new name -- override the current one.
+ * Note: if empty name is supplied -- use the title instead, see #6072.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! is_null( $name ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $post->post_name = sanitize_title( $name ? $name : $title, $post->ID );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2073,8 +2077,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> // Drafts and auto-drafts are just overwritten by autosave for the same user if the post is not locked.
</span><span class="cx" style="display: block; padding: 0 10px"> return edit_post( wp_slash( $post_data ) );
</span><span class="cx" style="display: block; padding: 0 10px"> } else {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Non-drafts or other users' drafts are not overwritten.
- // The autosave is stored in a special post revision for each user.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Non-drafts or other users' drafts are not overwritten.
+ * The autosave is stored in a special post revision for each user.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> return wp_create_post_autosave( wp_slash( $post_data ) );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span></span></pre></div>
<a id="trunksrcwpadminincludesrevisionphp"></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/revision.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/revision.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/revision.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -39,8 +39,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> return false;
</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">- // If comparing revisions, make sure we're dealing with the right post parent.
- // The parent post may be a 'revision' when revisions are disabled and we're looking at autosaves.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * If comparing revisions, make sure we are dealing with the right post parent.
+ * The parent post may be a 'revision' when revisions are disabled and we're looking at autosaves.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( $compare_from && $compare_from->post_parent !== $post->ID && $compare_from->ID !== $post->ID ) {
</span><span class="cx" style="display: block; padding: 0 10px"> return false;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -118,8 +120,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $diff = wp_text_diff( $content_from, $content_to, $args );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( ! $diff && 'post_title' === $field ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // It's a better user experience to still show the Title, even if it didn't change.
- // No, you didn't see this.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * It's a better user experience to still show the Title, even if it didn't change.
+ * No, you didn't see this.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $diff = '<table class="diff"><colgroup><col class="content diffsplit left"><col class="content diffsplit middle"><col class="content diffsplit right"></colgroup><tbody><tr>';
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // In split screen mode, show the title before/after side by side.
</span></span></pre></div>
<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 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/schema.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -548,8 +548,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> // 5.6.0
</span><span class="cx" style="display: block; padding: 0 10px"> 'auto_update_core_dev' => 'enabled',
</span><span class="cx" style="display: block; padding: 0 10px"> 'auto_update_core_minor' => 'enabled',
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Default to enabled for new installs.
- // See https://core.trac.wordpress.org/ticket/51742.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Default to enabled for new installs.
+ * See https://core.trac.wordpress.org/ticket/51742.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> 'auto_update_core_major' => 'enabled',
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // 5.8.0
</span></span></pre></div>
<a id="trunksrcwpadminincludestemplatephp"></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/template.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/template.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/template.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -165,8 +165,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $output = '';
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $parsed_args['checked_ontop'] ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Post-process $categories rather than adding an exclude to the get_terms() query
- // to keep the query the same across all posts (for any query cache).
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Post-process $categories rather than adding an exclude to the get_terms() query
+ * to keep the query the same across all posts (for any query cache).
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $checked_categories = array();
</span><span class="cx" style="display: block; padding: 0 10px"> $keys = array_keys( $categories );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1301,8 +1303,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> printf( '<div id="%s-sortables" class="meta-box-sortables">', esc_attr( $context ) );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Grab the ones the user has manually sorted.
- // Pull them out of their previous context/priority and into the one the user chose.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Grab the ones the user has manually sorted.
+ * Pull them out of their previous context/priority and into the one the user chose.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $sorted = get_user_option( "meta-box-order_$page" );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( ! $already_sorted && $sorted ) {
</span></span></pre></div>
<a id="trunksrcwpadminincludesupdatecorephp"></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/update-core.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/update-core.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/update-core.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1229,8 +1229,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in wp-admin/includes/update-core.php */
</span><span class="cx" style="display: block; padding: 0 10px"> apply_filters( 'update_feedback', __( 'Preparing to install the latest version…' ) );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Don't copy wp-content, we'll deal with that below.
- // We also copy version.php last so failed updates report their old version.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Don't copy wp-content, we'll deal with that below.
+ * We also copy version.php last so failed updates report their old version.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $skip = array( 'wp-content', 'wp-includes/version.php' );
</span><span class="cx" style="display: block; padding: 0 10px"> $check_is_writable = array();
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1397,8 +1399,10 @@
</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">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // If we don't have enough free space, it isn't worth trying again.
- // Unlikely to be hit due to the check in unzip_file().
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * If we don't have enough free space, it isn't worth trying again.
+ * Unlikely to be hit due to the check in unzip_file().
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> $available_space = function_exists( 'disk_free_space' ) ? @disk_free_space( ABSPATH ) : false;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $available_space && $total_size >= $available_space ) {
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1416,8 +1420,10 @@
</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">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Custom content directory needs updating now.
- // Copy languages.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Custom content directory needs updating now.
+ * Copy languages.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! is_wp_error( $result ) && $wp_filesystem->is_dir( $from . $distro . 'wp-content/languages' ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> if ( WP_LANG_DIR !== ABSPATH . WPINC . '/languages' || @is_dir( WP_LANG_DIR ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $lang_dir = WP_LANG_DIR;
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1455,8 +1461,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> // Remove maintenance file, we're done with potential site-breaking changes.
</span><span class="cx" style="display: block; padding: 0 10px"> $wp_filesystem->delete( $maintenance_file );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // 3.5 -> 3.5+ - an empty twentytwelve directory was created upon upgrade to 3.5 for some users,
- // preventing installation of Twenty Twelve.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * 3.5 -> 3.5+ - an empty twentytwelve directory was created upon upgrade to 3.5 for some users,
+ * preventing installation of Twenty Twelve.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( '3.5' === $old_wp_version ) {
</span><span class="cx" style="display: block; padding: 0 10px"> if ( is_dir( WP_CONTENT_DIR . '/themes/twentytwelve' )
</span><span class="cx" style="display: block; padding: 0 10px"> && ! file_exists( WP_CONTENT_DIR . '/themes/twentytwelve/style.css' )
</span></span></pre></div>
<a id="trunksrcwpadminincludesupgradephp"></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/upgrade.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/upgrade.php 2023-07-09 19:54:42 UTC (rev 56175)
+++ trunk/src/wp-admin/includes/upgrade.php 2023-07-09 20:05:43 UTC (rev 56176)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -440,8 +440,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $wpdb->query( $wpdb->prepare( "DELETE FROM $wpdb->usermeta WHERE user_id != %d AND meta_key = %s", $user_id, $table_prefix . 'user_level' ) );
</span><span class="cx" style="display: block; padding: 0 10px"> $wpdb->query( $wpdb->prepare( "DELETE FROM $wpdb->usermeta WHERE user_id != %d AND meta_key = %s", $user_id, $table_prefix . 'capabilities' ) );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Delete any caps that snuck into the previously active blog. (Hardcoded to blog 1 for now.)
- // TODO: Get previous_blog_id.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Delete any caps that snuck into the previously active blog. (Hardcoded to blog 1 for now.)
+ * TODO: Get previous_blog_id.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! is_super_admin( $user_id ) && 1 != $user_id ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $wpdb->delete(
</span><span class="cx" style="display: block; padding: 0 10px"> $wpdb->usermeta,
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1644,8 +1646,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> global $wp_current_db_version;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $wp_current_db_version < 11958 ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Previously, setting depth to 1 would redundantly disable threading,
- // but now 2 is the minimum depth to avoid confusion.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Previously, setting depth to 1 would redundantly disable threading,
+ * but now 2 is the minimum depth to avoid confusion.
+ */
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( get_option( 'thread_comments_depth' ) == '1' ) {
</span><span class="cx" style="display: block; padding: 0 10px"> update_option( 'thread_comments_depth', 2 );
</span><span class="cx" style="display: block; padding: 0 10px"> update_option( 'thread_comments', 0 );
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -3331,8 +3335,10 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $site_dir = WP_CONTENT_DIR . "/themes/$template";
</span><span class="cx" style="display: block; padding: 0 10px"> $default_dir = WP_CONTENT_DIR . '/themes/' . WP_DEFAULT_THEME;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Copy files from the default theme to the site theme.
- // $files = array( 'index.php', 'comments.php', 'comments-popup.php', 'footer.php', 'header.php', 'sidebar.php', 'style.css' );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /*
+ * Copy files from the default theme to the site theme.
+ * $files = array( 'index.php', 'comments.php', 'comments-popup.php', 'footer.php', 'header.php', 'sidebar.php', 'style.css' );
+ */
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $theme_dir = @opendir( $default_dir );
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $theme_dir ) {
</span></span></pre>
</div>
</div>
</body>
</html>