WordPress.org

Make WordPress Core

Changeset 19796


Ignore:
Timestamp:
01/31/12 14:28:30 (4 years ago)
Author:
nacin
Message:

wptexturize() does not need to staticize variables it only uses to set up variables it needs statically. see #19602.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/formatting.php

    r19795 r19796  
    2929function wptexturize($text) { 
    3030    global $wp_cockneyreplace; 
    31     static $opening_quote, $closing_quote, $opening_single_quote, $closing_single_quote, $en_dash, $em_dash, 
    32         $apos, $prime, $double_prime, $default_no_texturize_tags, $default_no_texturize_shortcodes, 
    33         $static_characters, $static_replacements, $dynamic_characters, $dynamic_replacements; 
     31    static $static_characters, $static_replacements, $dynamic_characters, $dynamic_replacements, 
     32        $default_no_texturize_tags, $default_no_texturize_shortcodes; 
    3433 
    3534    // No need to set up these static variables more than once 
    36     if ( empty( $opening_quote ) ) { 
     35    if ( ! isset( $static_characters ) ) { 
    3736        /* translators: opening curly double quote */ 
    3837        $opening_quote = _x( '“', 'opening curly double quote' ); 
Note: See TracChangeset for help on using the changeset viewer.