Skip to content

Commit

Permalink
wptexturize() does not need to staticize variables it only uses to se…
Browse files Browse the repository at this point in the history
…t up variables it needs statically. see #19602.

git-svn-id: http://svn.automattic.com/wordpress/trunk@19796 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information
nacin committed Jan 31, 2012
1 parent 1b7effa commit 2aec12b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions wp-includes/formatting.php
Expand Up @@ -28,12 +28,11 @@
*/
function wptexturize($text) {
global $wp_cockneyreplace;
static $opening_quote, $closing_quote, $opening_single_quote, $closing_single_quote, $en_dash, $em_dash,
$apos, $prime, $double_prime, $default_no_texturize_tags, $default_no_texturize_shortcodes,
$static_characters, $static_replacements, $dynamic_characters, $dynamic_replacements;
static $static_characters, $static_replacements, $dynamic_characters, $dynamic_replacements,
$default_no_texturize_tags, $default_no_texturize_shortcodes;

// No need to set up these static variables more than once
if ( empty( $opening_quote ) ) {
if ( ! isset( $static_characters ) ) {
/* translators: opening curly double quote */
$opening_quote = _x( '“', 'opening curly double quote' );
/* translators: closing curly double quote */
Expand Down

0 comments on commit 2aec12b

Please sign in to comment.