Skip to content

Commit

Permalink
Move AuthenticationResult to a separate case class
Browse files Browse the repository at this point in the history
  • Loading branch information
Rui Balau authored and wjglerum committed Nov 1, 2022
1 parent 8fb7454 commit f3168ef
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/com/lunatech/openconnect/Authenticate.scala
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ import play.mvc.Http
import scala.concurrent.{ExecutionContext, Future}
import scala.io.Source

case class AuthenticationResult(email: String, token: String)

class Authenticate @Inject()(configuration: Configuration, wsClient: WSClient)(implicit ec: ExecutionContext) extends Logging {

private val GOOGLE_CONF = "https://accounts.google.com/.well-known/openid-configuration"
Expand Down Expand Up @@ -141,7 +143,4 @@ class Authenticate @Inject()(configuration: Configuration, wsClient: WSClient)(i
}

private def getRevokeEndpoint: String = Json.parse(Source.fromURL(GOOGLE_CONF).mkString).get(REVOKE_ENDPOINT).asText()

case class AuthenticationResult(email: String, token: String)

}

0 comments on commit f3168ef

Please sign in to comment.