From fc79800fc57dd8996b3972b95cd373decd9b3f51 Mon Sep 17 00:00:00 2001 From: Dominik Schilling Date: Fri, 7 Oct 2016 18:32:29 +0000 Subject: [PATCH] Comments: Pass `$comment` to the `comment_max_links_url` filter. Props rachelbaker. Fixes #37955. Built from https://develop.svn.wordpress.org/trunk@38748 git-svn-id: http://core.svn.wordpress.org/trunk@38691 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/comment.php | 4 +++- wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-includes/comment.php b/wp-includes/comment.php index 220c45b14b..54a6fe1256 100644 --- a/wp-includes/comment.php +++ b/wp-includes/comment.php @@ -54,11 +54,13 @@ function check_comment($author, $email, $url, $comment, $user_ip, $user_agent, $ * Filters the number of links found in a comment. * * @since 3.0.0 + * @since 4.7.0 Added the `$comment` parameter. * * @param int $num_links The number of links found. * @param string $url Comment author's URL. Included in allowed links total. + * @param string $comment Content of the comment. */ - $num_links = apply_filters( 'comment_max_links_url', $num_links, $url ); + $num_links = apply_filters( 'comment_max_links_url', $num_links, $url, $comment ); /* * If the number of links in the comment exceeds the allowed amount, diff --git a/wp-includes/version.php b/wp-includes/version.php index 26abcec457..c76449da59 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.7-alpha-38747'; +$wp_version = '4.7-alpha-38748'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.