From c8cd8c8a366eaebf0d18f672f38d7897225cb80d Mon Sep 17 00:00:00 2001 From: Rachel Baker Date: Sat, 30 Jan 2016 22:12:29 +0000 Subject: [PATCH] Comments: Add back `$req` variable in `comments_template()`. The variables in `comments_template()` should never be assumed to be unused. This function includes the `comments.php` template file from the active theme or falls back to `theme-compat/comments.php`. This is why including a file within a function only brings pain and sorrow. Reverts r36322. See #35473. git-svn-id: https://develop.svn.wordpress.org/trunk@36425 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/comment-template.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/wp-includes/comment-template.php b/src/wp-includes/comment-template.php index 77a4dcd904..a1093b74ac 100644 --- a/src/wp-includes/comment-template.php +++ b/src/wp-includes/comment-template.php @@ -1256,6 +1256,8 @@ function comments_template( $file = '/comments.php', $separate_comments = false if ( empty($file) ) $file = '/comments.php'; + $req = get_option('require_name_email'); + /* * Comment author information fetched from the comment cookies. */