]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/edit.php
WordPress 4.0.1-scripts
[autoinstalls/wordpress.git] / wp-admin / edit.php
index a062b0911acba2885db444fa6c584df6351da701..241b8fbd3f901302869c6b7d8de0e3649bbe32e9 100644 (file)
@@ -12,6 +12,12 @@ require_once( dirname( __FILE__ ) . '/admin.php' );
 if ( ! $typenow )
        wp_die( __( 'Invalid post type' ) );
 
 if ( ! $typenow )
        wp_die( __( 'Invalid post type' ) );
 
+if ( 'attachment' === $typenow ) {
+       if ( wp_redirect( admin_url( 'upload.php' ) ) ) {
+               exit;
+       }
+}
+
 $post_type = $typenow;
 $post_type_object = get_post_type_object( $post_type );
 
 $post_type = $typenow;
 $post_type_object = get_post_type_object( $post_type );