mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-04-08 06:34:34 +00:00
Add @static* annotations where they are missing.
Initialize all static vars that are not, most to `null`. See #32444. git-svn-id: https://develop.svn.wordpress.org/trunk@32650 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -410,10 +410,11 @@ function register_theme_directory( $directory ) {
|
||||
*/
|
||||
function search_theme_directories( $force = false ) {
|
||||
global $wp_theme_directories;
|
||||
static $found_themes = null;
|
||||
|
||||
if ( empty( $wp_theme_directories ) )
|
||||
return false;
|
||||
|
||||
static $found_themes;
|
||||
if ( ! $force && isset( $found_themes ) )
|
||||
return $found_themes;
|
||||
|
||||
@@ -1105,7 +1106,7 @@ function get_header_image() {
|
||||
* @return object
|
||||
*/
|
||||
function _get_random_header_data() {
|
||||
static $_wp_random_header;
|
||||
static $_wp_random_header = null;
|
||||
|
||||
if ( empty( $_wp_random_header ) ) {
|
||||
global $_wp_default_headers;
|
||||
|
||||
Reference in New Issue
Block a user