Prevent the uploader getting stuck when deleting the only image from the gallery, props ocean90, fixes #15118

git-svn-id: http://svn.automattic.com/wordpress/trunk@18850 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz 2011-09-30 22:52:29 +00:00
parent e4605a562e
commit d7a9037fec
1 changed files with 1 additions and 1 deletions

View File

@ -117,7 +117,7 @@ if ( isset($_GET['inline']) ) {
$body_id = 'media-upload';
// let the action code decide how to handle the request
if ( $tab == 'type' || $tab == 'type_url' )
if ( $tab == 'type' || $tab == 'type_url' || ! array_key_exists( $tab , media_upload_tabs() ) )
do_action("media_upload_$type");
else
do_action("media_upload_$tab");