Changeset 41668 for trunk/src/wp-includes/ms-functions.php
- Timestamp:
- 10/02/2017 03:37:29 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/ms-functions.php
r41661 r41668 2202 2202 2203 2203 /** 2204 * Check whether a usermeta key has to do with the current blog.2205 *2206 * @since MU (3.0.0)2207 *2208 * @global wpdb $wpdb WordPress database abstraction object.2209 *2210 * @param string $key2211 * @param int $user_id Optional. Defaults to current user.2212 * @param int $blog_id Optional. Defaults to current blog.2213 * @return bool2214 */2215 function is_user_option_local( $key, $user_id = 0, $blog_id = 0 ) {2216 global $wpdb;2217 2218 $current_user = wp_get_current_user();2219 if ( $blog_id == 0 ) {2220 $blog_id = get_current_blog_id();2221 }2222 $local_key = $wpdb->get_blog_prefix( $blog_id ) . $key;2223 2224 return isset( $current_user->$local_key );2225 }2226 2227 /**2228 2204 * Check whether users can self-register, based on Network settings. 2229 2205 *
Note: See TracChangeset
for help on using the changeset viewer.