Skip to content

Commit

Permalink
Make sure that the HTTP response reasonPhrase is not blank or empty
Browse files Browse the repository at this point in the history
  • Loading branch information
jayohms committed Jan 14, 2021
1 parent 6e387fc commit a5285c3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ internal class TurboHttpRepository {

private fun reasonPhrase(response: Response): String {
// A reason phrase cannot be empty
return when (response.message.isEmpty()) {
return when (response.message.isBlank()) {
true -> "OK"
else -> response.message
}
Expand Down

0 comments on commit a5285c3

Please sign in to comment.