Changeset 30356 for trunk/src/wp-admin/themes.php
- Timestamp:
- 11/16/2014 06:15:29 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/themes.php
r29961 r30356 11 11 12 12 if ( !current_user_can('switch_themes') && !current_user_can('edit_theme_options') ) 13 wp_die( __( 'Cheatin’ uh?' ) );13 wp_die( __( 'Cheatin’ uh?' ), 403 ); 14 14 15 15 if ( current_user_can( 'switch_themes' ) && isset($_GET['action'] ) ) { … … 18 18 $theme = wp_get_theme( $_GET['stylesheet'] ); 19 19 if ( ! $theme->exists() || ! $theme->is_allowed() ) 20 wp_die( __( 'Cheatin’ uh?' ) );20 wp_die( __( 'Cheatin’ uh?' ), 403 ); 21 21 switch_theme( $theme->get_stylesheet() ); 22 22 wp_redirect( admin_url('themes.php?activated=true') ); … … 26 26 $theme = wp_get_theme( $_GET['stylesheet'] ); 27 27 if ( !current_user_can('delete_themes') || ! $theme->exists() ) 28 wp_die( __( 'Cheatin’ uh?' ) );28 wp_die( __( 'Cheatin’ uh?' ), 403 ); 29 29 delete_theme($_GET['stylesheet']); 30 30 wp_redirect( admin_url('themes.php?deleted=true') );
Note: See TracChangeset
for help on using the changeset viewer.