From 6bed9bf28ca6e15b35f3142e66f9fff9ff09867f Mon Sep 17 00:00:00 2001 From: Ammar Githam Date: Thu, 25 Mar 2021 19:47:33 +0900 Subject: [PATCH] Fix double voice message --- .../awais/instagrabber/viewmodels/DirectThreadViewModel.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/awais/instagrabber/viewmodels/DirectThreadViewModel.java b/app/src/main/java/awais/instagrabber/viewmodels/DirectThreadViewModel.java index 3e2a3603..1ca3c263 100644 --- a/app/src/main/java/awais/instagrabber/viewmodels/DirectThreadViewModel.java +++ b/app/src/main/java/awais/instagrabber/viewmodels/DirectThreadViewModel.java @@ -181,6 +181,7 @@ public class DirectThreadViewModel extends AndroidViewModel { MediaUtils.getVoiceInfo(contentResolver, uri, new MediaUtils.OnInfoLoadListener() { @Override public void onLoad(@Nullable final MediaUtils.VideoInfo videoInfo) { + if (videoInfo == null) return; threadManager.sendVoice(data, uri, result.getWaveform(),