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

git-svn-id: https://develop.svn.wordpress.org/trunk@18850 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz 2011-09-30 22:52:29 +00:00
parent 3a696e6995
commit 684727610f
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");