From b63ba3e84362f3d75393001284245f4336753dad Mon Sep 17 00:00:00 2001 From: Eric House Date: Tue, 21 May 2019 13:16:00 -0700 Subject: [PATCH] show toast when dropping duplicate invite if DEBUG I forget to enable that option too often. (No impact on release builds.) --- .../main/java/org/eehouse/android/xw4/XWServiceHelper.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWServiceHelper.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWServiceHelper.java index e86597e1f..6603182c3 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWServiceHelper.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWServiceHelper.java @@ -130,6 +130,10 @@ abstract class XWServiceHelper { } else if ( rowids.length < nli.nPlayersT ) { success = XWPrefs.getSecondInviteAllowed( mContext ); + if ( BuildConfig.DEBUG && !success ) { + DbgUtils.showf( mContext, "Dropping duplicate invite" ); + } + // Allowing a second game allows the common testing action of // sending invitation to myself. But we still need to check // for duplicates! forceChannel's hard to dig up, but works