mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-05 02:10:45 +01:00
Don't show both "update failed" and "update successful" messages when upgrading a theme fails due to connectivity problems.
Props SergeyBiryukov fixes #23027 git-svn-id: http://core.svn.wordpress.org/trunk@24276 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
7a1bc5769e
commit
9eff7bb71a
@ -1312,8 +1312,9 @@ class Bulk_Upgrader_Skin extends WP_Upgrader_Skin {
|
||||
|
||||
echo '<script type="text/javascript">jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').show();</script>';
|
||||
}
|
||||
if ( !empty($this->result) && !is_wp_error($this->result) ) {
|
||||
echo '<div class="updated"><p>' . sprintf($this->upgrader->strings['skin_update_successful'], $title, 'jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').toggle();jQuery(\'span\', this).toggle(); return false;') . '</p></div>';
|
||||
if ( $this->result && ! is_wp_error( $this->result ) ) {
|
||||
if ( ! $this->error )
|
||||
echo '<div class="updated"><p>' . sprintf($this->upgrader->strings['skin_update_successful'], $title, 'jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').toggle();jQuery(\'span\', this).toggle(); return false;') . '</p></div>';
|
||||
echo '<script type="text/javascript">jQuery(\'.waiting-' . esc_js($this->upgrader->update_current) . '\').hide();</script>';
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user