From 01b6bd9f38332de2dc2388a99afaad5518d98a10 Mon Sep 17 00:00:00 2001 From: Dominik Schilling Date: Sat, 21 Sep 2019 15:49:57 +0000 Subject: [PATCH] Site Health: Replace `wp_get_upload_dir()` with `wp_upload_dir()`. `wp_get_upload_dir()` returns the theoretical path of the uploads directory. When there was no upload yet the test returns an incorrect result (not writeable) because the directory doesn't exist. Switching to `wp_upload_dir()`, which creates the directory on the fly, ensures a proper test result. Fixes #47958. Built from https://develop.svn.wordpress.org/trunk@46228 git-svn-id: http://core.svn.wordpress.org/trunk@46040 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/class-wp-debug-data.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/class-wp-debug-data.php b/wp-admin/includes/class-wp-debug-data.php index 0039759ec9..4708e6187c 100644 --- a/wp-admin/includes/class-wp-debug-data.php +++ b/wp-admin/includes/class-wp-debug-data.php @@ -33,7 +33,7 @@ class WP_Debug_Data { global $wpdb; // Save few function calls. - $upload_dir = wp_get_upload_dir(); + $upload_dir = wp_upload_dir(); $permalink_structure = get_option( 'permalink_structure' ); $is_ssl = is_ssl(); $users_can_register = get_option( 'users_can_register' ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 5d0fe56281..9b47f5ccc3 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.3-alpha-46227'; +$wp_version = '5.3-alpha-46228'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.