From cd9d4b82919ffac63c1b9bd4a6f549e713085480 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Mon, 1 Mar 2010 08:50:27 +0000 Subject: [PATCH] Add __return_true() to complement __return_false(). see #12381 git-svn-id: https://develop.svn.wordpress.org/trunk@13526 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/functions.php | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index a2113e5018..b7b0109411 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -4047,11 +4047,24 @@ function _search_terms_tidy($t) { return trim($t, "\"'\n\r "); } +/** + * Returns true + * + * Useful for returning true to filters easily + * + * @see __return_false() + * @return bool true + */ +function __return_true() { + return true; +} + /** * Returns false * * Useful for returning false to filters easily - * + * + * @see __return_true() * @return bool false */ function __return_false() {