From 4478e8996d30d9b67b834aa0538acda29a58543a Mon Sep 17 00:00:00 2001 From: Eric House Date: Fri, 11 Dec 2020 12:44:15 -0800 Subject: [PATCH] include mqttdevid in app info sent for upgrade check --- .../org/eehouse/android/xw4/UpdateCheckReceiver.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/UpdateCheckReceiver.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/UpdateCheckReceiver.java index 0fe2b683f..a19b5e4c4 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/UpdateCheckReceiver.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/UpdateCheckReceiver.java @@ -33,10 +33,12 @@ import android.os.SystemClock; import java.io.File; import javax.net.ssl.HttpsURLConnection; -import org.eehouse.android.xw4.loc.LocUtils; import org.json.JSONArray; import org.json.JSONObject; +import org.eehouse.android.xw4.jni.XwJNI; +import org.eehouse.android.xw4.loc.LocUtils; + public class UpdateCheckReceiver extends BroadcastReceiver { private static final String TAG = UpdateCheckReceiver.class.getSimpleName(); private static final boolean LOG_QUERIES = false; @@ -66,6 +68,7 @@ public class UpdateCheckReceiver extends BroadcastReceiver { private static final String k_LEN = "len"; private static final String k_URL = "url"; private static final String k_DEVID = "did"; + private static final String k_MQTTDEVID = "devid"; private static final String k_DEBUG = "dbg"; private static final String k_XLATEINFO = "xlatinfo"; private static final String k_STRINGSHASH = "strings"; @@ -148,6 +151,10 @@ public class UpdateCheckReceiver extends BroadcastReceiver { appParams.put( k_DEBUG, BuildConfig.DEBUG ); params.put( k_APP, appParams ); params.put( k_DEVID, XWPrefs.getDevID( context ) ); + + String[] topic = {null}; + String devID = XwJNI.dvc_getMQTTDevID( topic ); + params.put( k_MQTTDEVID, devID ); } catch ( org.json.JSONException jse ) { Log.ex( TAG, jse ); }