X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/177fd6fefd2e3d5a0ea6591c71d660cabdb3c1a4..refs/tags/wordpress-2.6.2:/wp-admin/update.php diff --git a/wp-admin/update.php b/wp-admin/update.php index 34e93804..c3cd2892 100644 --- a/wp-admin/update.php +++ b/wp-admin/update.php @@ -2,8 +2,8 @@ require_once('admin.php'); -if ( !current_user_can('edit_plugins') ) - wp_die('

'.__('You do not have sufficient permissions to update plugins for this blog.').'

'); +if ( ! current_user_can('update_plugins') ) + wp_die(__('You do not have sufficient permissions to update plugins for this blog.')); function request_filesystem_credentials($form_post, $type = '', $error = false) { $req_cred = apply_filters('request_filesystem_credentials', '', $form_post, $type, $error); @@ -22,7 +22,7 @@ function request_filesystem_credentials($form_post, $type = '', $error = false) $credentials['hostname'] = defined('FTP_HOST') ? FTP_HOST : (!empty($_POST['hostname']) ? $_POST['hostname'] : $credentials['hostname']); $credentials['username'] = defined('FTP_USER') ? FTP_USER : (!empty($_POST['username']) ? $_POST['username'] : $credentials['username']); $credentials['password'] = defined('FTP_PASS') ? FTP_PASS : (!empty($_POST['password']) ? $_POST['password'] : $credentials['password']); - $credentials['ssl'] = defined('FTP_SSL') ? FTP_SSL : (!empty($_POST['ssl']) ? $_POST['ssl'] : $credentials['ssl']); + $credentials['ssl'] = defined('FTP_SSL') ? FTP_SSL : ( isset($_POST['ssl']) ? $_POST['ssl'] : $credentials['ssl']); if ( ! $error && !empty($credentials['password']) && !empty($credentials['username']) && !empty($credentials['hostname']) ) { $stored_credentials = $credentials; @@ -45,19 +45,19 @@ function request_filesystem_credentials($form_post, $type = '', $error = false)

- + - + - + - +
size="40" />
size="40" />
size="40" />'.__('(Password not shown)').''; ?>