Skip to content

Commit c694e9d

Browse files
author
John Belmonte
committed
Make logging of dry-run and opt-out on MP match Android SDK:
dry-run is verbose, and opt-out isn't logged.
1 parent 6505ac1 commit c694e9d

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

source/Plugins/GoogleAnalyticsV3/GoogleAnalyticsMPV3.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,14 +116,17 @@ internal void StopSession() {
116116
}
117117

118118
private void SendGaHitWithMeasurementProtocol(string url) {
119+
if (optOut) {
120+
return;
121+
}
119122
if (String.IsNullOrEmpty(url)) {
120123
if (GoogleAnalyticsV3.belowThreshold(logLevel, GoogleAnalyticsV3.DebugMode.WARNING)) {
121124
Debug.Log("No tracking code set for 'Other' platforms - hit will not be sent.");
122125
}
123126
return;
124127
}
125-
if (dryRun || optOut) {
126-
if (GoogleAnalyticsV3.belowThreshold(logLevel, GoogleAnalyticsV3.DebugMode.WARNING)) {
128+
if (dryRun) {
129+
if (GoogleAnalyticsV3.belowThreshold(logLevel, GoogleAnalyticsV3.DebugMode.VERBOSE)) {
127130
Debug.Log("Dry run or opt out enabled - hits will not be sent.");
128131
}
129132
return;

0 commit comments

Comments
 (0)