diff --git a/app b/app index 2e766025..ac10cd26 160000 --- a/app +++ b/app @@ -1 +1 @@ -Subproject commit 2e7660250b9c0f7599055d7e1eb3965a78f3db0e +Subproject commit ac10cd26939da7570f437efe5f6717148b41b0c4 diff --git a/src/main/java/io/lbry/browser/reactmodules/GalleryModule.java b/src/main/java/io/lbry/browser/reactmodules/GalleryModule.java index 265024db..ed905acd 100644 --- a/src/main/java/io/lbry/browser/reactmodules/GalleryModule.java +++ b/src/main/java/io/lbry/browser/reactmodules/GalleryModule.java @@ -221,18 +221,18 @@ public class GalleryModule extends ReactContextBaseJavaModule { } } } + + if (file.exists() && file.length() > 0 && GalleryModule.this.context != null) { + WritableMap params = Arguments.createMap(); + params.putString("id", id); + ((ReactApplicationContext) GalleryModule.this.context).getJSModule( + DeviceEventManagerModule.RCTDeviceEventEmitter.class).emit("onGalleryThumbnailChecked", params); + } } } return null; } - - protected void onPostExecute(Void result) { - if (GalleryModule.this.context != null) { - ((ReactApplicationContext) GalleryModule.this.context).getJSModule( - DeviceEventManagerModule.RCTDeviceEventEmitter.class).emit("onGalleryThumbnailsChecked", null); - } - } }).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR); }