Changeset 44717 for trunk/src/wp-admin/plugins.php
- Timestamp:
- 01/30/2019 11:00:30 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/plugins.php
r44524 r44717 390 390 break; 391 391 392 case 'resume':393 if ( ! current_user_can( 'resume_plugin', $plugin ) ) {394 wp_die( __( 'Sorry, you are not allowed to resume this plugin.' ) );395 }396 397 if ( is_multisite() && ! is_network_admin() && is_network_only_plugin( $plugin ) ) {398 wp_redirect( self_admin_url( "plugins.php?plugin_status=$status&paged=$page&s=$s" ) );399 exit;400 }401 402 check_admin_referer( 'resume-plugin_' . $plugin );403 404 $result = resume_plugin( $plugin, self_admin_url( 'plugins.php?error=resuming' ), is_network_admin() );405 406 if ( is_wp_error( $result ) ) {407 wp_die( $result );408 }409 410 wp_redirect( self_admin_url( "plugins.php?resume=true&plugin_status=$status&paged=$page&s=$s" ) );411 exit;412 413 392 default: 414 393 if ( isset( $_POST['checked'] ) ) { … … 510 489 ); 511 490 $errmsg .= ' ' . __( 'If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.' ); 512 } elseif ( 'resuming' === $_GET['error'] ) {513 $errmsg = __( 'Plugin could not be resumed because it triggered a <strong>fatal error</strong>.' );514 491 } else { 515 492 $errmsg = __( 'Plugin could not be activated because it triggered a <strong>fatal error</strong>.' ); … … 565 542 <?php elseif ( 'update-selected' == $action ) : ?> 566 543 <div id="message" class="updated notice is-dismissible"><p><?php _e( 'All selected plugins are up to date.' ); ?></p></div> 567 <?php elseif ( isset( $_GET['resume'] ) ) : ?>568 <div id="message" class="updated notice is-dismissible"><p><?php _e( 'Plugin <strong>resumed</strong>.' ); ?></p></div>569 544 <?php endif; ?> 570 545
Note: See TracChangeset
for help on using the changeset viewer.