From 2b651ee323bc8d73da2a7270fe1957fc7fbcf42c Mon Sep 17 00:00:00 2001 From: Moxie Marlinspike Date: Mon, 5 Feb 2018 12:08:40 -0800 Subject: [PATCH] Prevent NPE in #7375 --- .../securesms/components/webrtc/WebRtcAnswerDeclineButton.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/org/thoughtcrime/securesms/components/webrtc/WebRtcAnswerDeclineButton.java b/src/org/thoughtcrime/securesms/components/webrtc/WebRtcAnswerDeclineButton.java index b97f708cb0..54753935e5 100644 --- a/src/org/thoughtcrime/securesms/components/webrtc/WebRtcAnswerDeclineButton.java +++ b/src/org/thoughtcrime/securesms/components/webrtc/WebRtcAnswerDeclineButton.java @@ -297,7 +297,8 @@ public class WebRtcAnswerDeclineButton extends LinearLayout implements View.OnTo private void resetElements() { animating = false; complete = false; - animatorSet.cancel(); + + if (animatorSet != null) animatorSet.cancel(); swipeUpText.setTranslationY(0); fab.setTranslationY(0);