Add inline documentation for the run_wptexturize
filter.
Props miqrogroove for the original patch. Fixes #19550. git-svn-id: https://develop.svn.wordpress.org/trunk@28723 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
fe2ca3965e
commit
0d0f24fbbb
@ -37,6 +37,18 @@ function wptexturize($text) {
|
||||
|
||||
// No need to set up these static variables more than once
|
||||
if ( ! isset( $static_characters ) ) {
|
||||
/**
|
||||
* Filter whether to skip running `wptexturize()`.
|
||||
*
|
||||
* Passing false to the filter will effectively short-circuit `wptexturize()`.
|
||||
* returning the original text passed to the function instead.
|
||||
*
|
||||
* The filter runs only once, the first time `wptexturize()` is called.
|
||||
*
|
||||
* @since 4.0.0
|
||||
*
|
||||
* @param bool $run_texturize Whether to short-circuit `wptexturize()`.
|
||||
*/
|
||||
$run_texturize = apply_filters( 'run_wptexturize', $run_texturize );
|
||||
if ( false === $run_texturize ) {
|
||||
return $text;
|
||||
|
Loading…
Reference in New Issue
Block a user