@@ -197,7 +197,7 @@ internal class HttpClient(
197
197
PreferenceStores .ONESIGNAL ,
198
198
PreferenceOneSignalKeys .PREFS_OS_HTTP_CACHE_PREFIX + cacheKey,
199
199
)
200
- Logging .debug(" HttpClient: ${method ? : " GET" } $url - Using Cached response due to 304: " + cachedResponse)
200
+ Logging .debug(" HttpClient: Got Response = ${method ? : " GET" } ${con. url} - Using Cached response due to 304: " + cachedResponse)
201
201
202
202
// TODO: SHOULD RETURN OK INSTEAD OF NOT_MODIFIED TO MAKE TRANSPARENT?
203
203
retVal = HttpResponse (httpResponse, cachedResponse, retryAfterSeconds = retryAfter)
@@ -207,12 +207,12 @@ internal class HttpClient(
207
207
val scanner = Scanner (inputStream, " UTF-8" )
208
208
val json = if (scanner.useDelimiter(" \\ A" ).hasNext()) scanner.next() else " "
209
209
scanner.close()
210
- Logging .debug(" HttpClient: ${method ? : " GET" } $url - STATUS: $httpResponse JSON : " + json)
210
+ Logging .debug(" HttpClient: Got Response = ${method ? : " GET" } ${con. url} - STATUS: $httpResponse - Body : " + json)
211
211
212
212
if (cacheKey != null ) {
213
213
val eTag = con.getHeaderField(" etag" )
214
214
if (eTag != null ) {
215
- Logging .debug(" HttpClient: Response has etag of $eTag so caching the response." )
215
+ Logging .debug(" HttpClient: Got Response = Response has etag of $eTag so caching the response." )
216
216
217
217
_prefs .saveString(
218
218
PreferenceStores .ONESIGNAL ,
@@ -230,7 +230,7 @@ internal class HttpClient(
230
230
retVal = HttpResponse (httpResponse, json, retryAfterSeconds = retryAfter)
231
231
}
232
232
else -> {
233
- Logging .debug(" HttpClient: ${method ? : " GET" } $url - FAILED STATUS: $httpResponse " )
233
+ Logging .debug(" HttpClient: Got Response = ${method ? : " GET" } ${con. url} - FAILED STATUS: $httpResponse " )
234
234
235
235
var inputStream = con.errorStream
236
236
if (inputStream == null ) {
@@ -243,9 +243,9 @@ internal class HttpClient(
243
243
jsonResponse =
244
244
if (scanner.useDelimiter(" \\ A" ).hasNext()) scanner.next() else " "
245
245
scanner.close()
246
- Logging .warn(" HttpClient: $method RECEIVED JSON : $jsonResponse " )
246
+ Logging .warn(" HttpClient: Got Response = $method - STATUS: $httpResponse - Body : $jsonResponse " )
247
247
} else {
248
- Logging .warn(" HttpClient: $method HTTP Code : $httpResponse No response body!" )
248
+ Logging .warn(" HttpClient: Got Response = $method - STATUS : $httpResponse - No response body!" )
249
249
}
250
250
251
251
retVal = HttpResponse (httpResponse, jsonResponse, retryAfterSeconds = retryAfter)
0 commit comments