Skip to content

Commit 722e1e2

Browse files
committed
Merge pull request googleanalytics#47 from coquifrogs/master
Relaxes HTTP STATUS Header validation
2 parents 7cc2369 + 3defbb0 commit 722e1e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

source/Plugins/GoogleAnalyticsV3/GoogleAnalyticsMPV3.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,13 +152,13 @@ public IEnumerator HandleWWW(WWW request)
152152
{
153153
yield return request;
154154
if (request.responseHeaders.ContainsKey("STATUS")) {
155-
if (request.responseHeaders["STATUS"] == "HTTP/1.1 200 OK") {
155+
if (request.responseHeaders["STATUS"].Contains("200 OK")) {
156156
if (GoogleAnalyticsV3.belowThreshold(logLevel, GoogleAnalyticsV3.DebugMode.INFO)) {
157157
Debug.Log("Successfully sent Google Analytics hit.");
158158
}
159159
} else {
160160
if (GoogleAnalyticsV3.belowThreshold(logLevel, GoogleAnalyticsV3.DebugMode.WARNING)) {
161-
Debug.LogWarning("Google Analytics hit request rejected with" +
161+
Debug.LogWarning("Google Analytics hit request rejected with " +
162162
"status code " + request.responseHeaders["STATUS"]);
163163
}
164164
}

0 commit comments

Comments
 (0)