Skip to content

Commit

Permalink
#2231 Add NoAuthentication method in json writes
Browse files Browse the repository at this point in the history
  • Loading branch information
To-om committed Oct 28, 2021
1 parent 13f1412 commit 9389ff3
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ object Authentication {
case PasswordAuthentication(username, password) => Json.obj("type" -> "basic", "username" -> username, "password" -> password)
case KeyAuthentication(key, "") => Json.obj("type" -> "key", "key" -> key)
case KeyAuthentication(key, "Bearer ") => Json.obj("type" -> "bearer", "key" -> key)
case NoAuthentication => Json.obj("type" -> "none")
case KeyAuthentication(key, other) => Json.obj("type" -> other, "key" -> key)
}
implicit val format: Format[Authentication] = Format(reads, writes)
}
Expand Down

0 comments on commit 9389ff3

Please sign in to comment.