Return error if base dir empty. Props DD32. see #5586
git-svn-id: https://develop.svn.wordpress.org/trunk@7205 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
64aaf796c2
commit
0160d81eee
@ -142,6 +142,9 @@ function wp_update_plugin($plugin, $feedback = '') {
|
||||
|
||||
//Get the Base folder
|
||||
$base = $wp_filesystem->get_base_dir();
|
||||
|
||||
if ( empty($base) )
|
||||
return new WP_Error('fs_nowordpress', __('Unable to locate WordPress directory.'));
|
||||
|
||||
// Get the URL to the zip file
|
||||
$r = $current->response[ $plugin ];
|
||||
|
Loading…
Reference in New Issue
Block a user