Fix double logging for wallpaper settings icon activation

Bug: 137957099

Change-Id: Id95fa026c1e6f177ffbb03e99cc18ef03e9a37b5
diff --git a/src/com/android/launcher3/BaseDraggingActivity.java b/src/com/android/launcher3/BaseDraggingActivity.java
index d1d5e26..268b910 100644
--- a/src/com/android/launcher3/BaseDraggingActivity.java
+++ b/src/com/android/launcher3/BaseDraggingActivity.java
@@ -187,8 +187,9 @@
                         sourceContainer);
             }
             getUserEventDispatcher().logAppLaunch(v, intent, user);
-            getStatsLogManager().log(LAUNCHER_APP_LAUNCH_TAP, item == null ? null
-                    : item.buildProto());
+            if (item != null) {
+                getStatsLogManager().log(LAUNCHER_APP_LAUNCH_TAP, item.buildProto());
+            }
             return true;
         } catch (NullPointerException|ActivityNotFoundException|SecurityException e) {
             Toast.makeText(this, R.string.activity_not_found, Toast.LENGTH_SHORT).show();