Changeset 38636 for trunk/src/wp-includes/option.php
- Timestamp:
- 09/20/2016 09:38:08 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/option.php
r38388 r38636 1071 1071 * 1072 1072 * @global wpdb $wpdb 1073 * @global object $current_site 1073 1074 * 1074 1075 * @param int $network_id ID of the network. Can be null to default to the current network ID. … … 1078 1079 */ 1079 1080 function get_network_option( $network_id, $option, $default = false ) { 1080 global $wpdb ;1081 global $wpdb, $current_site; 1081 1082 1082 1083 if ( $network_id && ! is_numeric( $network_id ) ) { … … 1088 1089 // Fallback to the current network if a network ID is not specified. 1089 1090 if ( ! $network_id && is_multisite() ) { 1090 $network_id = get_current_site()->id;1091 $network_id = $current_site->id; 1091 1092 } 1092 1093 … … 1187 1188 * 1188 1189 * @global wpdb $wpdb 1190 * @global object $current_site 1189 1191 * 1190 1192 * @param int $network_id ID of the network. Can be null to default to the current network ID. … … 1194 1196 */ 1195 1197 function add_network_option( $network_id, $option, $value ) { 1196 global $wpdb ;1198 global $wpdb, $current_site; 1197 1199 1198 1200 if ( $network_id && ! is_numeric( $network_id ) ) { … … 1204 1206 // Fallback to the current network if a network ID is not specified. 1205 1207 if ( ! $network_id && is_multisite() ) { 1206 $network_id = get_current_site()->id;1208 $network_id = $current_site->id; 1207 1209 } 1208 1210 … … 1296 1298 * 1297 1299 * @global wpdb $wpdb 1300 * @global object $current_site 1298 1301 * 1299 1302 * @param int $network_id ID of the network. Can be null to default to the current network ID. … … 1302 1305 */ 1303 1306 function delete_network_option( $network_id, $option ) { 1304 global $wpdb ;1307 global $wpdb, $current_site; 1305 1308 1306 1309 if ( $network_id && ! is_numeric( $network_id ) ) { … … 1312 1315 // Fallback to the current network if a network ID is not specified. 1313 1316 if ( ! $network_id && is_multisite() ) { 1314 $network_id = get_current_site()->id;1317 $network_id = $current_site->id; 1315 1318 } 1316 1319 … … 1377 1380 * 1378 1381 * @global wpdb $wpdb 1382 * @global object $current_site 1379 1383 * 1380 1384 * @param int $network_id ID of the network. Can be null to default to the current network ID. … … 1384 1388 */ 1385 1389 function update_network_option( $network_id, $option, $value ) { 1386 global $wpdb ;1390 global $wpdb, $current_site; 1387 1391 1388 1392 if ( $network_id && ! is_numeric( $network_id ) ) { … … 1394 1398 // Fallback to the current network if a network ID is not specified. 1395 1399 if ( ! $network_id && is_multisite() ) { 1396 $network_id = get_current_site()->id;1400 $network_id = $current_site->id; 1397 1401 } 1398 1402
Note: See TracChangeset
for help on using the changeset viewer.