<!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>[46088] trunk: Docs: Fix placement of some duplicate hook references.</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/46088">46088</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/46088","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>SergeyBiryukov</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2019-09-10 19:22:07 +0000 (Tue, 10 Sep 2019)</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: Fix placement of some duplicate hook references.
Hook documentation should be on the line directly above the line containing the `do_action()` or `apply_filters()` call. The CS auto-fixing, which changed some inconsistent function calls to multi-line function calls, is part of the reason why this was no longer the case for a select group of duplicate hook references.
Includes minor code layout fixes.
See <a href="https://core.trac.wordpress.org/ticket/47110">#47110</a>.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunksrcwpadminincludesclasscustombackgroundphp">trunk/src/wp-admin/includes/class-custom-background.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswalkercategorychecklistphp">trunk/src/wp-admin/includes/class-walker-category-checklist.php</a></li>
<li><a href="#trunksrcwpadminincludestemplatephp">trunk/src/wp-admin/includes/template.php</a></li>
<li><a href="#trunksrcwpcontentthemestwentyelevenauthorphp">trunk/src/wp-content/themes/twentyeleven/author.php</a></li>
<li><a href="#trunksrcwpcontentthemestwentyelevencontentsinglephp">trunk/src/wp-content/themes/twentyeleven/content-single.php</a></li>
<li><a href="#trunksrcwpcontentthemestwentytenauthorphp">trunk/src/wp-content/themes/twentyten/author.php</a></li>
<li><a href="#trunksrcwpcontentthemestwentytenloopsinglephp">trunk/src/wp-content/themes/twentyten/loop-single.php</a></li>
<li><a href="#trunksrcwpincludesclasswalkercategoryphp">trunk/src/wp-includes/class-walker-category.php</a></li>
<li><a href="#trunksrcwpincludesclasswpimageeditorimagickphp">trunk/src/wp-includes/class-wp-image-editor-imagick.php</a></li>
<li><a href="#trunksrcwpincludesclasswpstylesphp">trunk/src/wp-includes/class.wp-styles.php</a></li>
<li><a href="#trunksrcwpincludescommenttemplatephp">trunk/src/wp-includes/comment-template.php</a></li>
<li><a href="#trunksrcwpincludesgeneraltemplatephp">trunk/src/wp-includes/general-template.php</a></li>
<li><a href="#trunksrcwpincludesrestapiendpointsclasswprestautosavescontrollerphp">trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php</a></li>
<li><a href="#trunksrcwpincludesuserphp">trunk/src/wp-includes/user.php</a></li>
<li><a href="#trunktestsphpunittestsgeneralpaginateLinksphp">trunk/tests/phpunit/tests/general/paginateLinks.php</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpadminincludesclasscustombackgroundphp"></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/class-custom-background.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-custom-background.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-admin/includes/class-custom-background.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -584,9 +584,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> if ( ! current_user_can( 'edit_theme_options' ) || ! isset( $_POST['attachment_id'] ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> exit;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> $attachment_id = absint( $_POST['attachment_id'] );
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /** This filter is documented in wp-admin/includes/media.php */
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> $sizes = array_keys(
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /** This filter is documented in wp-admin/includes/media.php */
</ins><span class="cx" style="display: block; padding: 0 10px"> apply_filters(
</span><span class="cx" style="display: block; padding: 0 10px"> 'image_size_names_choose',
</span><span class="cx" style="display: block; padding: 0 10px"> array(
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -597,12 +599,14 @@
</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">- $size = 'thumbnail';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ $size = 'thumbnail';
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( in_array( $_POST['size'], $sizes ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $size = esc_attr( $_POST['size'] );
</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"> update_post_meta( $attachment_id, '_wp_attachment_is_custom_background', get_option( 'stylesheet' ) );
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> $url = wp_get_attachment_image_src( $attachment_id, $size );
</span><span class="cx" style="display: block; padding: 0 10px"> $thumbnail = wp_get_attachment_image_src( $attachment_id, 'thumbnail' );
</span><span class="cx" style="display: block; padding: 0 10px"> set_theme_mod( 'background_image', esc_url_raw( $url[0] ) );
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswalkercategorychecklistphp"></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/class-walker-category-checklist.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-walker-category-checklist.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-admin/includes/class-walker-category-checklist.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -95,17 +95,17 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $aria_checked = '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">- /** This filter is documented in wp-includes/category-template.php */
</del><span class="cx" style="display: block; padding: 0 10px"> $output .= "\n" . '<li' . $class . '>' .
</span><span class="cx" style="display: block; padding: 0 10px"> '<div class="' . $inner_class . '" data-term-id=' . $category->term_id .
</span><span class="cx" style="display: block; padding: 0 10px"> ' tabindex="0" role="checkbox" aria-checked="' . $aria_checked . '">' .
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /** This filter is documented in wp-includes/category-template.php */
</ins><span class="cx" style="display: block; padding: 0 10px"> esc_html( apply_filters( 'the_category', $category->name, '', '' ) ) . '</div>';
</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">- /** This filter is documented in wp-includes/category-template.php */
</del><span class="cx" style="display: block; padding: 0 10px"> $output .= "\n<li id='{$taxonomy}-{$category->term_id}'$class>" .
</span><span class="cx" style="display: block; padding: 0 10px"> '<label class="selectit"><input value="' . $category->term_id . '" type="checkbox" name="' . $name . '[]" id="in-' . $taxonomy . '-' . $category->term_id . '"' .
</span><span class="cx" style="display: block; padding: 0 10px"> checked( in_array( $category->term_id, $args['selected_cats'] ), true, false ) .
</span><span class="cx" style="display: block; padding: 0 10px"> disabled( empty( $args['disabled'] ), false, false ) . ' /> ' .
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /** This filter is documented in wp-includes/category-template.php */
</ins><span class="cx" style="display: block; padding: 0 10px"> esc_html( apply_filters( 'the_category', $category->name, '', '' ) ) . '</label>';
</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="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 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-admin/includes/template.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -309,7 +309,6 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $title = esc_textarea( trim( $post->post_title ) );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /** This filter is documented in wp-admin/edit-tag-form.php */
</del><span class="cx" style="display: block; padding: 0 10px"> echo '
</span><span class="cx" style="display: block; padding: 0 10px"> <div class="hidden" id="inline_' . $post->ID . '">
</span><span class="cx" style="display: block; padding: 0 10px"> <div class="post_title">' . $title . '</div>' .
</span></span></pre></div>
<a id="trunksrcwpcontentthemestwentyelevenauthorphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-content/themes/twentyeleven/author.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-content/themes/twentyeleven/author.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-content/themes/twentyeleven/author.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -59,7 +59,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="cx" style="display: block; padding: 0 10px"> * @param int The height and width avatar dimension in pixels. Default 60.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentyeleven_author_bio_avatar_size', 60 ) );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $author_bio_avatar_size = apply_filters( 'twentyeleven_author_bio_avatar_size', 60 );
+ echo get_avatar( get_the_author_meta( 'user_email' ), $author_bio_avatar_size );
</ins><span class="cx" style="display: block; padding: 0 10px"> ?>
</span><span class="cx" style="display: block; padding: 0 10px"> </div><!-- #author-avatar -->
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-description">
</span></span></pre></div>
<a id="trunksrcwpcontentthemestwentyelevencontentsinglephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-content/themes/twentyeleven/content-single.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-content/themes/twentyeleven/content-single.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-content/themes/twentyeleven/content-single.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -66,7 +66,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-avatar">
</span><span class="cx" style="display: block; padding: 0 10px"> <?php
</span><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in author.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentyeleven_author_bio_avatar_size', 68 ) );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $author_bio_avatar_size = apply_filters( 'twentyeleven_author_bio_avatar_size', 68 );
+ echo get_avatar( get_the_author_meta( 'user_email' ), $author_bio_avatar_size );
</ins><span class="cx" style="display: block; padding: 0 10px"> ?>
</span><span class="cx" style="display: block; padding: 0 10px"> </div><!-- #author-avatar -->
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-description">
</span></span></pre></div>
<a id="trunksrcwpcontentthemestwentytenauthorphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-content/themes/twentyten/author.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-content/themes/twentyten/author.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-content/themes/twentyten/author.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -47,7 +47,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="cx" style="display: block; padding: 0 10px"> * @param int The height and width avatar dimensions in pixels. Default 60.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentyten_author_bio_avatar_size', 60 ) );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $author_bio_avatar_size = apply_filters( 'twentyten_author_bio_avatar_size', 60 );
+ echo get_avatar( get_the_author_meta( 'user_email' ), $author_bio_avatar_size );
</ins><span class="cx" style="display: block; padding: 0 10px"> ?>
</span><span class="cx" style="display: block; padding: 0 10px"> </div><!-- #author-avatar -->
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-description">
</span></span></pre></div>
<a id="trunksrcwpcontentthemestwentytenloopsinglephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-content/themes/twentyten/loop-single.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-content/themes/twentyten/loop-single.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-content/themes/twentyten/loop-single.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -50,7 +50,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-avatar">
</span><span class="cx" style="display: block; padding: 0 10px"> <?php
</span><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in author.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentyten_author_bio_avatar_size', 60 ) );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $author_bio_avatar_size = apply_filters( 'twentyten_author_bio_avatar_size', 60 );
+ echo get_avatar( get_the_author_meta( 'user_email' ), $author_bio_avatar_size );
</ins><span class="cx" style="display: block; padding: 0 10px"> ?>
</span><span class="cx" style="display: block; padding: 0 10px"> </div><!-- #author-avatar -->
</span><span class="cx" style="display: block; padding: 0 10px"> <div id="author-description">
</span></span></pre></div>
<a id="trunksrcwpincludesclasswalkercategoryphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/class-walker-category.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/class-walker-category.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/class-walker-category.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -97,11 +97,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><span class="cx" style="display: block; padding: 0 10px"> public function start_el( &$output, $category, $depth = 0, $args = array(), $id = 0 ) {
</span><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in wp-includes/category-template.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $cat_name = apply_filters(
- 'list_cats',
- esc_attr( $category->name ),
- $category
- );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $cat_name = apply_filters( 'list_cats', esc_attr( $category->name ), $category );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // Don't generate an element if the category name is empty.
</span><span class="cx" style="display: block; padding: 0 10px"> if ( '' === $cat_name ) {
</span></span></pre></div>
<a id="trunksrcwpincludesclasswpimageeditorimagickphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/class-wp-image-editor-imagick.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/class-wp-image-editor-imagick.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/class-wp-image-editor-imagick.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -665,9 +665,9 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $perms = $stat['mode'] & 0000666; //same permissions as parent folder, strip off the executable bits
</span><span class="cx" style="display: block; padding: 0 10px"> chmod( $filename, $perms );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /** This filter is documented in wp-includes/class-wp-image-editor-gd.php */
</del><span class="cx" style="display: block; padding: 0 10px"> return array(
</span><span class="cx" style="display: block; padding: 0 10px"> 'path' => $filename,
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /** This filter is documented in wp-includes/class-wp-image-editor-gd.php */
</ins><span class="cx" style="display: block; padding: 0 10px"> 'file' => wp_basename( apply_filters( 'image_make_intermediate_size', $filename ) ),
</span><span class="cx" style="display: block; padding: 0 10px"> 'width' => $this->size['width'],
</span><span class="cx" style="display: block; padding: 0 10px"> 'height' => $this->size['height'],
</span></span></pre></div>
<a id="trunksrcwpincludesclasswpstylesphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/class.wp-styles.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/class.wp-styles.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/class.wp-styles.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -199,6 +199,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $rel = isset( $obj->extra['alt'] ) && $obj->extra['alt'] ? 'alternate stylesheet' : 'stylesheet';
</span><span class="cx" style="display: block; padding: 0 10px"> $title = isset( $obj->extra['title'] ) ? "title='" . esc_attr( $obj->extra['title'] ) . "'" : '';
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $tag = "<link rel='$rel' id='$handle-css' $title href='$href' type='text/css' media='$media' />\n";
+
</ins><span class="cx" style="display: block; padding: 0 10px"> /**
</span><span class="cx" style="display: block; padding: 0 10px"> * Filters the HTML link tag of an enqueued style.
</span><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -211,7 +213,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> * @param string $href The stylesheet's source URL.
</span><span class="cx" style="display: block; padding: 0 10px"> * @param string $media The stylesheet's media attribute.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $tag = apply_filters( 'style_loader_tag', "<link rel='$rel' id='$handle-css' $title href='$href' type='text/css' media='$media' />\n", $handle, $href, $media );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $tag = apply_filters( 'style_loader_tag', $tag, $handle, $href, $media );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( 'rtl' === $this->text_direction && isset( $obj->extra['rtl'] ) && $obj->extra['rtl'] ) {
</span><span class="cx" style="display: block; padding: 0 10px"> if ( is_bool( $obj->extra['rtl'] ) || 'replace' === $obj->extra['rtl'] ) {
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -221,8 +223,9 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $rtl_href = $this->_css_href( $obj->extra['rtl'], $ver, "$handle-rtl" );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $rtl_tag = "<link rel='$rel' id='$handle-rtl-css' $title href='$rtl_href' type='text/css' media='$media' />\n";
</ins><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in wp-includes/class.wp-styles.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $rtl_tag = apply_filters( 'style_loader_tag', "<link rel='$rel' id='$handle-rtl-css' $title href='$rtl_href' type='text/css' media='$media' />\n", $handle, $rtl_href, $media );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $rtl_tag = apply_filters( 'style_loader_tag', $rtl_tag, $handle, $rtl_href, $media );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $obj->extra['rtl'] === 'replace' ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $tag = $rtl_tag;
</span></span></pre></div>
<a id="trunksrcwpincludescommenttemplatephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/comment-template.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/comment-template.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/comment-template.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2274,20 +2274,64 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $req = get_option( 'require_name_email' );
</span><span class="cx" style="display: block; padding: 0 10px"> $html_req = ( $req ? " required='required'" : '' );
</span><span class="cx" style="display: block; padding: 0 10px"> $html5 = 'html5' === $args['format'];
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $fields = array(
- 'author' => '<p class="comment-form-author">' . '<label for="author">' . __( 'Name' ) . ( $req ? ' <span class="required">*</span>' : '' ) . '</label> ' .
- '<input id="author" name="author" type="text" value="' . esc_attr( $commenter['comment_author'] ) . '" size="30" maxlength="245"' . $html_req . ' /></p>',
- 'email' => '<p class="comment-form-email"><label for="email">' . __( 'Email' ) . ( $req ? ' <span class="required">*</span>' : '' ) . '</label> ' .
- '<input id="email" name="email" ' . ( $html5 ? 'type="email"' : 'type="text"' ) . ' value="' . esc_attr( $commenter['comment_author_email'] ) . '" size="30" maxlength="100" aria-describedby="email-notes"' . $html_req . ' /></p>',
- 'url' => '<p class="comment-form-url"><label for="url">' . __( 'Website' ) . '</label> ' .
- '<input id="url" name="url" ' . ( $html5 ? 'type="url"' : 'type="text"' ) . ' value="' . esc_attr( $commenter['comment_author_url'] ) . '" size="30" maxlength="200" /></p>',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ $fields = array(
+ 'author' => sprintf(
+ '<p class="comment-form-author">%s %s</p>',
+ sprintf(
+ '<label for="author">%s%s</label>',
+ __( 'Name' ),
+ ( $req ? ' <span class="required">*</span>' : '' )
+ ),
+ sprintf(
+ '<input id="author" name="author" type="text" value="%s" size="30" maxlength="245"%s />',
+ esc_attr( $commenter['comment_author'] ),
+ $html_req
+ )
+ ),
+ 'email' => sprintf(
+ '<p class="comment-form-email">%s %s</p>',
+ sprintf(
+ '<label for="email">%s%s</label>',
+ __( 'Email' ),
+ ( $req ? ' <span class="required">*</span>' : '' )
+ ),
+ sprintf(
+ '<input id="email" name="email" %s value="%s" size="30" maxlength="100" aria-describedby="email-notes"%s />',
+ ( $html5 ? 'type="email"' : 'type="text"' ),
+ esc_attr( $commenter['comment_author_email'] ),
+ $html_req
+ )
+ ),
+ 'url' => sprintf(
+ '<p class="comment-form-url">%s %s</p>',
+ sprintf(
+ '<label for="url">%s</label>',
+ __( 'Website' )
+ ),
+ sprintf(
+ '<input id="url" name="url" %s value="%s" size="30" maxlength="200" />',
+ ( $html5 ? 'type="url"' : 'type="text"' ),
+ esc_attr( $commenter['comment_author_url'] )
+ )
+ ),
</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"> if ( has_action( 'set_comment_cookies', 'wp_set_comment_cookies' ) && get_option( 'show_comments_cookies_opt_in' ) ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $consent = empty( $commenter['comment_author_email'] ) ? '' : ' checked="checked"';
- $fields['cookies'] = '<p class="comment-form-cookies-consent"><input id="wp-comment-cookies-consent" name="wp-comment-cookies-consent" type="checkbox" value="yes"' . $consent . ' />' .
- '<label for="wp-comment-cookies-consent">' . __( 'Save my name, email, and website in this browser for the next time I comment.' ) . '</label></p>';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $consent = empty( $commenter['comment_author_email'] ) ? '' : ' checked="checked"';
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $fields['cookies'] = sprintf(
+ '<p class="comment-form-cookies-consent">%s %s</p>',
+ sprintf(
+ '<input id="wp-comment-cookies-consent" name="wp-comment-cookies-consent" type="checkbox" value="yes"%s />',
+ $consent
+ ),
+ sprintf(
+ '<label for="wp-comment-cookies-consent">%s</label>',
+ __( 'Save my name, email, and website in this browser for the next time I comment.' )
+ )
+ );
+
</ins><span class="cx" style="display: block; padding: 0 10px"> // Ensure that the passed fields include cookies consent.
</span><span class="cx" style="display: block; padding: 0 10px"> if ( isset( $args['fields'] ) && ! isset( $args['fields']['cookies'] ) ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $args['fields']['cookies'] = $fields['cookies'];
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2307,27 +2351,48 @@
</span><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="cx" style="display: block; padding: 0 10px"> * @param string[] $fields Array of the default comment fields.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $fields = apply_filters( 'comment_form_default_fields', $fields );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $fields = apply_filters( 'comment_form_default_fields', $fields );
+
</ins><span class="cx" style="display: block; padding: 0 10px"> $defaults = array(
</span><span class="cx" style="display: block; padding: 0 10px"> 'fields' => $fields,
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- 'comment_field' => '<p class="comment-form-comment"><label for="comment">' . _x( 'Comment', 'noun' ) . '</label> <textarea id="comment" name="comment" cols="45" rows="8" maxlength="65525" required="required"></textarea></p>',
- /** This filter is documented in wp-includes/link-template.php */
- 'must_log_in' => '<p class="must-log-in">' . sprintf(
- /* translators: %s: Login URL. */
- __( 'You must be <a href="%s">logged in</a> to post a comment.' ),
- wp_login_url( apply_filters( 'the_permalink', get_permalink( $post_id ), $post_id ) )
- ) . '</p>',
- /** This filter is documented in wp-includes/link-template.php */
- 'logged_in_as' => '<p class="logged-in-as">' . sprintf(
- /* translators: 1: Edit user link, 2: Accessibility text, 3: User name, 4: Logout URL. */
- __( '<a href="%1$s" aria-label="%2$s">Logged in as %3$s</a>. <a href="%4$s">Log out?</a>' ),
- get_edit_user_link(),
- /* translators: %s: User name. */
- esc_attr( sprintf( __( 'Logged in as %s. Edit your profile.' ), $user_identity ) ),
- $user_identity,
- wp_logout_url( apply_filters( 'the_permalink', get_permalink( $post_id ), $post_id ) )
- ) . '</p>',
- 'comment_notes_before' => '<p class="comment-notes"><span id="email-notes">' . __( 'Your email address will not be published.' ) . '</span>' . ( $req ? $required_text : '' ) . '</p>',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ 'comment_field' => sprintf(
+ '<p class="comment-form-comment">%s %s</p>',
+ sprintf(
+ '<label for="comment">%s</label>',
+ _x( 'Comment', 'noun' )
+ ),
+ '<textarea id="comment" name="comment" cols="45" rows="8" maxlength="65525" required="required"></textarea>'
+ ),
+ 'must_log_in' => sprintf(
+ '<p class="must-log-in">%s</p>',
+ sprintf(
+ /* translators: %s: Login URL. */
+ __( 'You must be <a href="%s">logged in</a> to post a comment.' ),
+ /** This filter is documented in wp-includes/link-template.php */
+ wp_login_url( apply_filters( 'the_permalink', get_permalink( $post_id ), $post_id ) )
+ )
+ ),
+ 'logged_in_as' => sprintf(
+ '<p class="logged-in-as">%s</p>',
+ sprintf(
+ /* translators: 1: Edit user link, 2: Accessibility text, 3: User name, 4: Logout URL. */
+ __( '<a href="%1$s" aria-label="%2$s">Logged in as %3$s</a>. <a href="%4$s">Log out?</a>' ),
+ get_edit_user_link(),
+ /* translators: %s: User name. */
+ esc_attr( sprintf( __( 'Logged in as %s. Edit your profile.' ), $user_identity ) ),
+ $user_identity,
+ /** This filter is documented in wp-includes/link-template.php */
+ wp_logout_url( apply_filters( 'the_permalink', get_permalink( $post_id ), $post_id ) )
+ )
+ ),
+ 'comment_notes_before' => sprintf(
+ '<p class="comment-notes">%s%s</p>',
+ sprintf(
+ '<span id="email-notes">%s</span>',
+ __( 'Your email address will not be published.' )
+ ),
+ ( $req ? $required_text : '' )
+ ),
</ins><span class="cx" style="display: block; padding: 0 10px"> 'comment_notes_after' => '',
</span><span class="cx" style="display: block; padding: 0 10px"> 'action' => site_url( '/wp-comments-post.php' ),
</span><span class="cx" style="display: block; padding: 0 10px"> 'id_form' => 'commentform',
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2385,6 +2450,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> echo $args['title_reply_after'];
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( get_option( 'comment_registration' ) && ! is_user_logged_in() ) :
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> echo $args['must_log_in'];
</span><span class="cx" style="display: block; padding: 0 10px"> /**
</span><span class="cx" style="display: block; padding: 0 10px"> * Fires after the HTML-formatted 'must log in after' message in the comment form.
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2392,165 +2458,175 @@
</span><span class="cx" style="display: block; padding: 0 10px"> * @since 3.0.0
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><span class="cx" style="display: block; padding: 0 10px"> do_action( 'comment_form_must_log_in_after' );
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> else :
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- ?>
- <form action="<?php echo esc_url( $args['action'] ); ?>" method="post" id="<?php echo esc_attr( $args['id_form'] ); ?>" class="<?php echo esc_attr( $args['class_form'] ); ?>"<?php echo $html5 ? ' novalidate' : ''; ?>>
- <?php
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ printf(
+ '<form action="%s" method="post" id="%s" class="%s"%s>',
+ esc_url( $args['action'] ),
+ esc_attr( $args['id_form'] ),
+ esc_attr( $args['class_form'] ),
+ ( $html5 ? ' novalidate' : '' )
+ );
+
+ /**
+ * Fires at the top of the comment form, inside the form tag.
+ *
+ * @since 3.0.0
+ */
+ do_action( 'comment_form_top' );
+
+ if ( is_user_logged_in() ) :
+
</ins><span class="cx" style="display: block; padding: 0 10px"> /**
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- * Fires at the top of the comment form, inside the form tag.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ * Filters the 'logged in' message for the comment form for display.
</ins><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="cx" style="display: block; padding: 0 10px"> * @since 3.0.0
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ *
+ * @param string $args_logged_in The logged-in-as HTML-formatted message.
+ * @param array $commenter An array containing the comment author's
+ * username, email, and URL.
+ * @param string $user_identity If the commenter is a registered user,
+ * the display name, blank otherwise.
</ins><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- do_action( 'comment_form_top' );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ echo apply_filters( 'comment_form_logged_in', $args['logged_in_as'], $commenter, $user_identity );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if ( is_user_logged_in() ) :
- /**
- * Filters the 'logged in' message for the comment form for display.
- *
- * @since 3.0.0
- *
- * @param string $args_logged_in The logged-in-as HTML-formatted message.
- * @param array $commenter An array containing the comment author's
- * username, email, and URL.
- * @param string $user_identity If the commenter is a registered user,
- * the display name, blank otherwise.
- */
- echo apply_filters( 'comment_form_logged_in', $args['logged_in_as'], $commenter, $user_identity );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Fires after the is_user_logged_in() check in the comment form.
+ *
+ * @since 3.0.0
+ *
+ * @param array $commenter An array containing the comment author's
+ * username, email, and URL.
+ * @param string $user_identity If the commenter is a registered user,
+ * the display name, blank otherwise.
+ */
+ do_action( 'comment_form_logged_in_after', $commenter, $user_identity );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Fires after the is_user_logged_in() check in the comment form.
- *
- * @since 3.0.0
- *
- * @param array $commenter An array containing the comment author's
- * username, email, and URL.
- * @param string $user_identity If the commenter is a registered user,
- * the display name, blank otherwise.
- */
- do_action( 'comment_form_logged_in_after', $commenter, $user_identity );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ else :
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- else :
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ echo $args['comment_notes_before'];
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo $args['comment_notes_before'];
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ endif;
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- endif;
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ // Prepare an array of all fields, including the textarea
+ $comment_fields = array( 'comment' => $args['comment_field'] ) + (array) $args['fields'];
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Prepare an array of all fields, including the textarea
- $comment_fields = array( 'comment' => $args['comment_field'] ) + (array) $args['fields'];
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Filters the comment form fields, including the textarea.
+ *
+ * @since 4.4.0
+ *
+ * @param array $comment_fields The comment fields.
+ */
+ $comment_fields = apply_filters( 'comment_form_fields', $comment_fields );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Filters the comment form fields, including the textarea.
- *
- * @since 4.4.0
- *
- * @param array $comment_fields The comment fields.
- */
- $comment_fields = apply_filters( 'comment_form_fields', $comment_fields );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ // Get an array of field names, excluding the textarea
+ $comment_field_keys = array_diff( array_keys( $comment_fields ), array( 'comment' ) );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Get an array of field names, excluding the textarea
- $comment_field_keys = array_diff( array_keys( $comment_fields ), array( 'comment' ) );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ // Get the first and the last field name, excluding the textarea
+ $first_field = reset( $comment_field_keys );
+ $last_field = end( $comment_field_keys );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // Get the first and the last field name, excluding the textarea
- $first_field = reset( $comment_field_keys );
- $last_field = end( $comment_field_keys );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ foreach ( $comment_fields as $name => $field ) {
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- foreach ( $comment_fields as $name => $field ) {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if ( 'comment' === $name ) {
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if ( 'comment' === $name ) {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Filters the content of the comment textarea field for display.
+ *
+ * @since 3.0.0
+ *
+ * @param string $args_comment_field The content of the comment textarea field.
+ */
+ echo apply_filters( 'comment_form_field_comment', $field );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ echo $args['comment_notes_after'];
+
+ } elseif ( ! is_user_logged_in() ) {
+
+ if ( $first_field === $name ) {
</ins><span class="cx" style="display: block; padding: 0 10px"> /**
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- * Filters the content of the comment textarea field for display.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ * Fires before the comment fields in the comment form, excluding the textarea.
</ins><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="cx" style="display: block; padding: 0 10px"> * @since 3.0.0
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- *
- * @param string $args_comment_field The content of the comment textarea field.
</del><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo apply_filters( 'comment_form_field_comment', $field );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ do_action( 'comment_form_before_fields' );
+ }
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo $args['comment_notes_after'];
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Filters a comment form field for display.
+ *
+ * The dynamic portion of the filter hook, `$name`, refers to the name
+ * of the comment form field. Such as 'author', 'email', or 'url'.
+ *
+ * @since 3.0.0
+ *
+ * @param string $field The HTML-formatted output of the comment form field.
+ */
+ echo apply_filters( "comment_form_field_{$name}", $field ) . "\n";
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- } elseif ( ! is_user_logged_in() ) {
-
- if ( $first_field === $name ) {
- /**
- * Fires before the comment fields in the comment form, excluding the textarea.
- *
- * @since 3.0.0
- */
- do_action( 'comment_form_before_fields' );
- }
-
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if ( $last_field === $name ) {
</ins><span class="cx" style="display: block; padding: 0 10px"> /**
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- * Filters a comment form field for display.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ * Fires after the comment fields in the comment form, excluding the textarea.
</ins><span class="cx" style="display: block; padding: 0 10px"> *
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- * The dynamic portion of the filter hook, `$name`, refers to the name
- * of the comment form field. Such as 'author', 'email', or 'url'.
- *
</del><span class="cx" style="display: block; padding: 0 10px"> * @since 3.0.0
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- *
- * @param string $field The HTML-formatted output of the comment form field.
</del><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo apply_filters( "comment_form_field_{$name}", $field ) . "\n";
-
- if ( $last_field === $name ) {
- /**
- * Fires after the comment fields in the comment form, excluding the textarea.
- *
- * @since 3.0.0
- */
- do_action( 'comment_form_after_fields' );
- }
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ do_action( 'comment_form_after_fields' );
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ }
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $submit_button = sprintf(
- $args['submit_button'],
- esc_attr( $args['name_submit'] ),
- esc_attr( $args['id_submit'] ),
- esc_attr( $args['class_submit'] ),
- esc_attr( $args['label_submit'] )
- );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $submit_button = sprintf(
+ $args['submit_button'],
+ esc_attr( $args['name_submit'] ),
+ esc_attr( $args['id_submit'] ),
+ esc_attr( $args['class_submit'] ),
+ esc_attr( $args['label_submit'] )
+ );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Filters the submit button for the comment form to display.
- *
- * @since 4.2.0
- *
- * @param string $submit_button HTML markup for the submit button.
- * @param array $args Arguments passed to comment_form().
- */
- $submit_button = apply_filters( 'comment_form_submit_button', $submit_button, $args );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Filters the submit button for the comment form to display.
+ *
+ * @since 4.2.0
+ *
+ * @param string $submit_button HTML markup for the submit button.
+ * @param array $args Arguments passed to comment_form().
+ */
+ $submit_button = apply_filters( 'comment_form_submit_button', $submit_button, $args );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $submit_field = sprintf(
- $args['submit_field'],
- $submit_button,
- get_comment_id_fields( $post_id )
- );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $submit_field = sprintf(
+ $args['submit_field'],
+ $submit_button,
+ get_comment_id_fields( $post_id )
+ );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Filters the submit field for the comment form to display.
- *
- * The submit field includes the submit button, hidden fields for the
- * comment form, and any wrapper markup.
- *
- * @since 4.2.0
- *
- * @param string $submit_field HTML markup for the submit field.
- * @param array $args Arguments passed to comment_form().
- */
- echo apply_filters( 'comment_form_submit_field', $submit_field, $args );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Filters the submit field for the comment form to display.
+ *
+ * The submit field includes the submit button, hidden fields for the
+ * comment form, and any wrapper markup.
+ *
+ * @since 4.2.0
+ *
+ * @param string $submit_field HTML markup for the submit field.
+ * @param array $args Arguments passed to comment_form().
+ */
+ echo apply_filters( 'comment_form_submit_field', $submit_field, $args );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Fires at the bottom of the comment form, inside the closing </form> tag.
- *
- * @since 1.5.0
- *
- * @param int $post_id The post ID.
- */
- do_action( 'comment_form', $post_id );
- ?>
- </form>
- <?php endif; ?>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /**
+ * Fires at the bottom of the comment form, inside the closing </form> tag.
+ *
+ * @since 1.5.0
+ *
+ * @param int $post_id The post ID.
+ */
+ do_action( 'comment_form', $post_id );
+
+ echo '</form>';
+
+ endif;
+ ?>
</ins><span class="cx" style="display: block; padding: 0 10px"> </div><!-- #respond -->
</span><span class="cx" style="display: block; padding: 0 10px"> <?php
</span><span class="cx" style="display: block; padding: 0 10px">
</span></span></pre></div>
<a id="trunksrcwpincludesgeneraltemplatephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/general-template.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/general-template.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/general-template.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4042,6 +4042,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $mid_size < 0 ) {
</span><span class="cx" style="display: block; padding: 0 10px"> $mid_size = 2;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> $add_args = $args['add_args'];
</span><span class="cx" style="display: block; padding: 0 10px"> $r = '';
</span><span class="cx" style="display: block; padding: 0 10px"> $page_links = array();
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4055,18 +4056,27 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> $link .= $args['add_fragment'];
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /**
- * Filters the paginated links for the given archive pages.
- *
- * @since 3.0.0
- *
- * @param string $link The paginated link URL.
- */
- $page_links[] = '<a class="prev page-numbers" href="' . esc_url( apply_filters( 'paginate_links', $link ) ) . '">' . $args['prev_text'] . '</a>';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $page_links[] = sprintf(
+ '<a class="prev page-numbers" href="%s">%s</a>',
+ /**
+ * Filters the paginated links for the given archive pages.
+ *
+ * @since 3.0.0
+ *
+ * @param string $link The paginated link URL.
+ */
+ esc_url( apply_filters( 'paginate_links', $link ) ),
+ $args['prev_text']
+ );
</ins><span class="cx" style="display: block; padding: 0 10px"> endif;
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> for ( $n = 1; $n <= $total; $n++ ) :
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $n == $current ) :
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $page_links[] = "<span aria-current='" . esc_attr( $args['aria_current'] ) . "' class='page-numbers current'>" . $args['before_page_number'] . number_format_i18n( $n ) . $args['after_page_number'] . '</span>';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $page_links[] = sprintf(
+ '<span aria-current="%s" class="page-numbers current">%s</span>',
+ esc_attr( $args['aria_current'] ),
+ $args['before_page_number'] . number_format_i18n( $n ) . $args['after_page_number']
+ );
</ins><span class="cx" style="display: block; padding: 0 10px"> $dots = true;
</span><span class="cx" style="display: block; padding: 0 10px"> else :
</span><span class="cx" style="display: block; padding: 0 10px"> if ( $args['show_all'] || ( $n <= $end_size || ( $current && $n >= $current - $mid_size && $n <= $current + $mid_size ) || $n > $total - $end_size ) ) :
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4077,8 +4087,12 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> $link .= $args['add_fragment'];
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /** This filter is documented in wp-includes/general-template.php */
- $page_links[] = "<a class='page-numbers' href='" . esc_url( apply_filters( 'paginate_links', $link ) ) . "'>" . $args['before_page_number'] . number_format_i18n( $n ) . $args['after_page_number'] . '</a>';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $page_links[] = sprintf(
+ '<a class="page-numbers" href="%s">%s</a>',
+ /** This filter is documented in wp-includes/general-template.php */
+ esc_url( apply_filters( 'paginate_links', $link ) ),
+ $args['before_page_number'] . number_format_i18n( $n ) . $args['after_page_number']
+ );
</ins><span class="cx" style="display: block; padding: 0 10px"> $dots = true;
</span><span class="cx" style="display: block; padding: 0 10px"> elseif ( $dots && ! $args['show_all'] ) :
</span><span class="cx" style="display: block; padding: 0 10px"> $page_links[] = '<span class="page-numbers dots">' . __( '…' ) . '</span>';
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4086,6 +4100,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> endif;
</span><span class="cx" style="display: block; padding: 0 10px"> endif;
</span><span class="cx" style="display: block; padding: 0 10px"> endfor;
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( $args['prev_next'] && $current && $current < $total ) :
</span><span class="cx" style="display: block; padding: 0 10px"> $link = str_replace( '%_%', $args['format'], $args['base'] );
</span><span class="cx" style="display: block; padding: 0 10px"> $link = str_replace( '%#%', $current + 1, $link );
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4094,9 +4109,14 @@
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> $link .= $args['add_fragment'];
</span><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- /** This filter is documented in wp-includes/general-template.php */
- $page_links[] = '<a class="next page-numbers" href="' . esc_url( apply_filters( 'paginate_links', $link ) ) . '">' . $args['next_text'] . '</a>';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $page_links[] = sprintf(
+ '<a class="next page-numbers" href="%s">%s</a>',
+ /** This filter is documented in wp-includes/general-template.php */
+ esc_url( apply_filters( 'paginate_links', $link ) ),
+ $args['next_text']
+ );
</ins><span class="cx" style="display: block; padding: 0 10px"> endif;
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> switch ( $args['type'] ) {
</span><span class="cx" style="display: block; padding: 0 10px"> case 'array':
</span><span class="cx" style="display: block; padding: 0 10px"> return $page_links;
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4111,6 +4131,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $r = join( "\n", $page_links );
</span><span class="cx" style="display: block; padding: 0 10px"> break;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
</ins><span class="cx" style="display: block; padding: 0 10px"> return $r;
</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">@@ -4322,18 +4343,25 @@
</span><span class="cx" style="display: block; padding: 0 10px"> * @param bool $force_echo Optional. Force the stylesheet link to be printed rather than enqueued.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><span class="cx" style="display: block; padding: 0 10px"> function wp_admin_css( $file = 'wp-admin', $force_echo = false ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- // For backward compatibility
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ // For backward compatibility.
</ins><span class="cx" style="display: block; padding: 0 10px"> $handle = 0 === strpos( $file, 'css/' ) ? substr( $file, 4 ) : $file;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( wp_styles()->query( $handle ) ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if ( $force_echo || did_action( 'wp_print_styles' ) ) { // we already printed the style queue. Print this one immediately
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if ( $force_echo || did_action( 'wp_print_styles' ) ) {
+ // We already printed the style queue. Print this one immediately.
</ins><span class="cx" style="display: block; padding: 0 10px"> wp_print_styles( $handle );
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- } else { // Add to style queue
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ } else {
+ // Add to style queue.
</ins><span class="cx" style="display: block; padding: 0 10px"> wp_enqueue_style( $handle );
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> return;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $stylesheet_link = sprintf(
+ "<link rel='stylesheet' href='%s' type='text/css' />\n",
+ esc_url( wp_admin_css_uri( $file ) )
+ );
+
</ins><span class="cx" style="display: block; padding: 0 10px"> /**
</span><span class="cx" style="display: block; padding: 0 10px"> * Filters the stylesheet link to the specified CSS file.
</span><span class="cx" style="display: block; padding: 0 10px"> *
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4345,11 +4373,16 @@
</span><span class="cx" style="display: block; padding: 0 10px"> * @param string $file Style handle name or filename (without ".css" extension)
</span><span class="cx" style="display: block; padding: 0 10px"> * relative to wp-admin/. Defaults to 'wp-admin'.
</span><span class="cx" style="display: block; padding: 0 10px"> */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo apply_filters( 'wp_admin_css', "<link rel='stylesheet' href='" . esc_url( wp_admin_css_uri( $file ) ) . "' type='text/css' />\n", $file );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ echo apply_filters( 'wp_admin_css', $stylesheet_link, $file );
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> if ( function_exists( 'is_rtl' ) && is_rtl() ) {
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $rtl_stylesheet_link = sprintf(
+ "<link rel='stylesheet' href='%s' type='text/css' />\n",
+ esc_url( wp_admin_css_uri( "$file-rtl" ) )
+ );
+
</ins><span class="cx" style="display: block; padding: 0 10px"> /** This filter is documented in wp-includes/general-template.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- echo apply_filters( 'wp_admin_css', "<link rel='stylesheet' href='" . esc_url( wp_admin_css_uri( "$file-rtl" ) ) . "' type='text/css' />\n", "$file-rtl" );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ echo apply_filters( 'wp_admin_css', $rtl_stylesheet_link, "$file-rtl" );
</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></pre></div>
<a id="trunksrcwpincludesrestapiendpointsclasswprestautosavescontrollerphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -358,9 +358,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> return new WP_Error( 'rest_autosave_no_changes', __( 'There is nothing to save. The autosave and the post content are the same.' ), array( 'status' => 400 ) );
</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">- /**
- * This filter is documented in wp-admin/post.php.
- */
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ /** This filter is documented in wp-admin/post.php */
</ins><span class="cx" style="display: block; padding: 0 10px"> do_action( 'wp_creating_autosave', $new_autosave );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> // wp_update_post expects escaped array.
</span></span></pre></div>
<a id="trunksrcwpincludesuserphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/user.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/user.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/src/wp-includes/user.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2503,8 +2503,8 @@
</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"> /** This filter is documented in wp-includes/user.php */
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $illegal_user_logins = array_map( 'strtolower', (array) apply_filters( 'illegal_user_logins', array() ) );
- if ( in_array( strtolower( $sanitized_user_login ), $illegal_user_logins ) ) {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $illegal_user_logins = (array) apply_filters( 'illegal_user_logins', array() );
+ if ( in_array( strtolower( $sanitized_user_login ), array_map( 'strtolower', $illegal_user_logins ) ) ) {
</ins><span class="cx" style="display: block; padding: 0 10px"> $errors->add( 'invalid_username', __( '<strong>ERROR</strong>: Sorry, that username is not allowed.' ) );
</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="trunktestsphpunittestsgeneralpaginateLinksphp"></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/general/paginateLinks.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/tests/phpunit/tests/general/paginateLinks.php 2019-09-10 19:03:04 UTC (rev 46087)
+++ trunk/tests/phpunit/tests/general/paginateLinks.php 2019-09-10 19:22:07 UTC (rev 46088)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -16,11 +16,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $page50 = get_pagenum_link( 50 );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $expected = <<<EXPECTED
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<span aria-current='page' class='page-numbers current'>1</span>
-<a class='page-numbers' href='$page2'>2</a>
-<a class='page-numbers' href='$page3'>3</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<span aria-current="page" class="page-numbers current">1</span>
+<a class="page-numbers" href="$page2">2</a>
+<a class="page-numbers" href="$page3">3</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <span class="page-numbers dots">…</span>
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$page50'>50</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$page50">50</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <a class="next page-numbers" href="$page2">Next »</a>
</span><span class="cx" style="display: block; padding: 0 10px"> EXPECTED;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -34,11 +34,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $page50 = home_url( '/page/50/' );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $expected = <<<EXPECTED
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<span aria-current='page' class='page-numbers current'>1</span>
-<a class='page-numbers' href='$page2'>2</a>
-<a class='page-numbers' href='$page3'>3</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<span aria-current="page" class="page-numbers current">1</span>
+<a class="page-numbers" href="$page2">2</a>
+<a class="page-numbers" href="$page3">3</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <span class="page-numbers dots">…</span>
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$page50'>50</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$page50">50</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <a class="next page-numbers" href="$page2">Next »</a>
</span><span class="cx" style="display: block; padding: 0 10px"> EXPECTED;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -58,12 +58,12 @@
</span><span class="cx" style="display: block; padding: 0 10px"> $page50 = get_pagenum_link( 50 );
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $expected = <<<EXPECTED
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$home'>1</a>
-<span aria-current='page' class='page-numbers current'>2</span>
-<a class='page-numbers' href='$page3'>3</a>
-<a class='page-numbers' href='$page4'>4</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$home">1</a>
+<span aria-current="page" class="page-numbers current">2</span>
+<a class="page-numbers" href="$page3">3</a>
+<a class="page-numbers" href="$page4">4</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <span class="page-numbers dots">…</span>
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$page50'>50</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$page50">50</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> EXPECTED;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $links = paginate_links(
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -84,12 +84,12 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> $expected = <<<EXPECTED
</span><span class="cx" style="display: block; padding: 0 10px"> <a class="prev page-numbers" href="$home">« Previous</a>
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$home'>1</a>
-<span aria-current='page' class='page-numbers current'>2</span>
-<a class='page-numbers' href='$page3'>3</a>
-<a class='page-numbers' href='$page4'>4</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$home">1</a>
+<span aria-current="page" class="page-numbers current">2</span>
+<a class="page-numbers" href="$page3">3</a>
+<a class="page-numbers" href="$page4">4</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <span class="page-numbers dots">…</span>
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<a class='page-numbers' href='$page50'>50</a>
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<a class="page-numbers" href="$page50">50</a>
</ins><span class="cx" style="display: block; padding: 0 10px"> <a class="next page-numbers" href="$page3">Next »</a>
</span><span class="cx" style="display: block; padding: 0 10px"> EXPECTED;
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -333,7 +333,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">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $this->assertContains( "<span aria-current='page' class='page-numbers current'>3</span>", $links );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $this->assertContains( '<span aria-current="page" class="page-numbers current">3</span>', $links );
</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">@@ -355,6 +355,6 @@
</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"> $page_2_url = home_url() . '?foo=2';
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- $this->assertContains( "<a class='page-numbers' href='$page_2_url'>2</a>", $links );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ $this->assertContains( "<a class=\"page-numbers\" href=\"$page_2_url\">2</a>", $links );
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span></span></pre>
</div>
</div>
</body>
</html>