Skip to content

Commit e4aaad5

Browse files
committed
Added more logging
1 parent cbd69ef commit e4aaad5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Branch-SDK/src/main/java/io/branch/referral/TrackingController.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ void disableTracking(Context context, boolean disableTracking, @Nullable Branch.
2929
// If the tracking state is already set to the desired state, then return instantly
3030
if (trackingDisabled == disableTracking) {
3131
if (callback != null) {
32+
BranchLogger.v("Tracking state is already set to " + disableTracking + ". Returning the same to the callback");
3233
callback.onTrackingStateChanged(trackingDisabled, Branch.getInstance().getFirstReferringParams(), null);
3334
}
3435
return;
@@ -38,11 +39,13 @@ void disableTracking(Context context, boolean disableTracking, @Nullable Branch.
3839
PrefHelper.getInstance(context).setBool(PrefHelper.KEY_TRACKING_STATE, disableTracking);
3940

4041
if (disableTracking) {
42+
BranchLogger.v("Tracking disabled. Clearing all pending requests");
4143
onTrackingDisabled(context);
4244
if (callback != null) {
4345
callback.onTrackingStateChanged(true, null, null);
4446
}
4547
} else {
48+
BranchLogger.v("Tracking enabled. Registering app init");
4649
onTrackingEnabled((referringParams, error) -> {
4750
if (callback != null) {
4851
callback.onTrackingStateChanged(false, referringParams, error);

0 commit comments

Comments
 (0)