From 123fae73b5e16fba3de8b47fd0b1f63a006f7df3 Mon Sep 17 00:00:00 2001 From: Andrew Ozz Date: Wed, 10 Sep 2014 22:39:39 +0000 Subject: [PATCH] Media: revert enabling of multi-file uploading for mobile devices. Currently only iOS Safari supports it but has a bug that prevents uploading of videos. Fixes #29602 git-svn-id: https://develop.svn.wordpress.org/trunk@29729 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/media.php | 6 ++++++ src/wp-includes/media.php | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php index f9962827de..1060979e33 100644 --- a/src/wp-admin/includes/media.php +++ b/src/wp-admin/includes/media.php @@ -1780,6 +1780,12 @@ $plupload_init = array( 'multipart_params' => $post_params, ); +// Currently only iOS Safari supports multiple files uploading but has a bug that prevents uploading of videos +// when enabled. See #29602. +if ( wp_is_mobile() ) { + $plupload_init['multi_selection'] = false; +} + /** * Filter the default Plupload settings. * diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php index 4a0fa392a7..0f9b777477 100644 --- a/src/wp-includes/media.php +++ b/src/wp-includes/media.php @@ -2542,6 +2542,12 @@ function wp_plupload_default_settings() { ), ); + // Currently only iOS Safari supports multiple files uploading but has a bug that prevents uploading of videos + // when enabled. See #29602. + if ( wp_is_mobile() ) { + $defaults['multi_selection'] = false; + } + /** * Filter the Plupload default settings. *