From 0ff45c39836a5e7ef8181220af6932b9c229e2d9 Mon Sep 17 00:00:00 2001 From: Marko Savic Date: Fri, 31 Jan 2020 11:40:59 +0100 Subject: [PATCH] Add a case when we are sharing media from the device (#1817) --- .../wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/react-native-gutenberg-bridge/android/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java b/react-native-gutenberg-bridge/android/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java index c553873850..48a65c8f33 100644 --- a/react-native-gutenberg-bridge/android/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java +++ b/react-native-gutenberg-bridge/android/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java @@ -643,6 +643,12 @@ public void appendUploadMediaFiles(ArrayList mediaList) { rnMediaList.addAll(mediaList); mPendingMediaUploadCallback.onUploadMediaFileSelected(rnMediaList); } + } else { + // This case is for media that is shared from the device + for (Media mediaToAppend : mediaList) { + sendOrDeferAppendMediaSignal(mediaToAppend.getId(), mediaToAppend.getUrl(), + mediaToAppend.getType()); + } } mAppendsMultipleSelectedToSiblingBlocks = false;