Bug 1294730 - Send distribution referrers to Adjust. r=rnewman a=lizzard
authorMichael Kaply <mozilla@kaply.com>
Fri, 26 Aug 2016 09:26:42 -0500
changeset 349972 4124f3349865847168c3b3db3b4d690e1b4e0214
parent 349971 4aacede9f1b374ad665bbb117c1d34e29a1b3992
child 349973 350ef810694c3704431f65c91bd83b9f2e933622
push id1230
push userjlund@mozilla.com
push dateMon, 31 Oct 2016 18:13:35 +0000
treeherdermozilla-release@5e06e3766db2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrnewman, lizzard
bugs1294730
milestone50.0a2
Bug 1294730 - Send distribution referrers to Adjust. r=rnewman a=lizzard
mobile/android/base/java/org/mozilla/gecko/distribution/ReferrerReceiver.java
--- a/mobile/android/base/java/org/mozilla/gecko/distribution/ReferrerReceiver.java
+++ b/mobile/android/base/java/org/mozilla/gecko/distribution/ReferrerReceiver.java
@@ -64,16 +64,22 @@ public class ReferrerReceiver extends Br
             } catch (Exception e) {
                 Log.e(LOGTAG, "Got exception in Adjust's onReceive; ignoring referrer intent.", e);
             }
             return;
         }
 
         if (TextUtils.equals(referrer.campaign, DISTRIBUTION_UTM_CAMPAIGN)) {
             Distribution.onReceivedReferrer(context, referrer);
+            // We want Adjust information for OTA distributions as well
+            try {
+                AdjustConstants.getAdjustHelper().onReceive(context, intent);
+            } catch (Exception e) {
+                Log.e(LOGTAG, "Got exception in Adjust's onReceive for distribution.", e);
+            }
         } else {
             Log.d(LOGTAG, "Not downloading distribution: non-matching campaign.");
             // If this is a Mozilla campaign, pass the campaign along to Gecko.
             // It'll pretend to be a "playstore" distribution for BLP purposes.
             propagateMozillaCampaign(referrer);
         }
 
         // Broadcast a secondary, local intent to allow test code to respond.