From a41c99d5913bb4a10f501f1a2d2085d7997b7950 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Wed, 6 Jul 2016 10:02:06 +0300 Subject: [PATCH] True npe fix --- .../src/net/osmand/plus/voice/TTSCommandPlayerImpl.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java b/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java index 55b444ccf1..b688084b0b 100644 --- a/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java +++ b/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java @@ -144,10 +144,10 @@ public class TTSCommandPlayerImpl extends AbstractPrologCommandPlayer { i.putExtra("messageType", PEBBLE_ALERT); i.putExtra("sender", "OsmAnd"); i.putExtra("notificationData", notificationData); - if (cxt != null) { - ctx.sendBroadcast(i); - log.info("Send message to pebble " + bld.toString()); - } + if (ctx != null) { + ctx.sendBroadcast(i); + log.info("Send message to pebble " + bld.toString()); + } }