amplitude / Amplitude-Kotlin

Amplitude Kotlin SDK
MIT License
27 stars 10 forks source link

fix: Only parse response body when a body is expected #185

Closed izaaz closed 4 months ago

izaaz commented 4 months ago

Summary

This PR fixes two issues

  1. Allow empty response bodies for successful requests (#184)
  2. When the server returns a 503, the response body is not an HTML page and not a json object. So try parsing response and don't fail (#163)

Checklist

izaaz commented 4 months ago

Looks good. Thanks @izaaz.

Lint is failing in CI. I have gotten in the habit of running ./gradlew ktlintCheck locally, not sure if there is a way to intergrate this lint style into the IDE(s)

Good to know! Thanks @justin-fiedler

github-actions[bot] commented 4 months ago

:tada: This PR is included in version 1.16.2 :tada:

The release is available on:

Your semantic-release bot :package::rocket: