Changeset 25289 for trunk/src/wp-includes/option.php
- Timestamp:
- 09/06/2013 06:09:24 PM (12 years ago)
- File:
-
- 1 edited
-
trunk/src/wp-includes/option.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/option.php
r25109 r25289 166 166 */ 167 167 function wp_load_core_site_options( $site_id = null ) { 168 global $wpdb , $_wp_using_ext_object_cache;169 170 if ( !is_multisite() || $_wp_using_ext_object_cache|| defined( 'WP_INSTALLING' ) )168 global $wpdb; 169 170 if ( !is_multisite() || wp_using_ext_object_cache() || defined( 'WP_INSTALLING' ) ) 171 171 return; 172 172 … … 405 405 */ 406 406 function delete_transient( $transient ) { 407 global $_wp_using_ext_object_cache;408 409 407 do_action( 'delete_transient_' . $transient, $transient ); 410 408 411 if ( $_wp_using_ext_object_cache) {409 if ( wp_using_ext_object_cache() ) { 412 410 $result = wp_cache_delete( $transient, 'transient' ); 413 411 } else { … … 444 442 */ 445 443 function get_transient( $transient ) { 446 global $_wp_using_ext_object_cache;447 448 444 $pre = apply_filters( 'pre_transient_' . $transient, false ); 449 445 if ( false !== $pre ) 450 446 return $pre; 451 447 452 if ( $_wp_using_ext_object_cache) {448 if ( wp_using_ext_object_cache() ) { 453 449 $value = wp_cache_get( $transient, 'transient' ); 454 450 } else { … … 494 490 */ 495 491 function set_transient( $transient, $value, $expiration = 0 ) { 496 global $_wp_using_ext_object_cache;497 498 492 $value = apply_filters( 'pre_set_transient_' . $transient, $value ); 499 493 500 if ( $_wp_using_ext_object_cache) {494 if ( wp_using_ext_object_cache() ) { 501 495 $result = wp_cache_set( $transient, $value, 'transient', $expiration ); 502 496 } else { … … 971 965 */ 972 966 function delete_site_transient( $transient ) { 973 global $_wp_using_ext_object_cache;974 975 967 do_action( 'delete_site_transient_' . $transient, $transient ); 976 if ( $_wp_using_ext_object_cache) {968 if ( wp_using_ext_object_cache() ) { 977 969 $result = wp_cache_delete( $transient, 'site-transient' ); 978 970 } else { … … 1009 1001 */ 1010 1002 function get_site_transient( $transient ) { 1011 global $_wp_using_ext_object_cache;1012 1013 1003 $pre = apply_filters( 'pre_site_transient_' . $transient, false ); 1014 1004 if ( false !== $pre ) 1015 1005 return $pre; 1016 1006 1017 if ( $_wp_using_ext_object_cache) {1007 if ( wp_using_ext_object_cache() ) { 1018 1008 $value = wp_cache_get( $transient, 'site-transient' ); 1019 1009 } else { … … 1059 1049 */ 1060 1050 function set_site_transient( $transient, $value, $expiration = 0 ) { 1061 global $_wp_using_ext_object_cache;1062 1063 1051 $value = apply_filters( 'pre_set_site_transient_' . $transient, $value ); 1064 1052 1065 if ( $_wp_using_ext_object_cache) {1053 if ( wp_using_ext_object_cache() ) { 1066 1054 $result = wp_cache_set( $transient, $value, 'site-transient', $expiration ); 1067 1055 } else {
Note: See TracChangeset
for help on using the changeset viewer.