t2v / play2-auth

Play2.x Authentication and Authorization module
Apache License 2.0
608 stars 142 forks source link

Compilation error in Auth.scala #181

Closed mycaule closed 6 years ago

mycaule commented 8 years ago

I have got this error at compilation

LoginLogout.scala:24: ';' expected but '=>' found.
[error]   self: Controller with AuthConfig =>
[error]                                    ^
[error] one error found

What do I need to import to solve this? I don't understand the point of the => at the end of line. Thank you

trait Logout {
  import scala.concurrent.ExecutionContext

  self: Controller with AuthConfig =>

  def gotoLogoutSucceeded(implicit request: RequestHeader, ctx: ExecutionContext): Future[Result] = {
    gotoLogoutSucceeded(logoutSucceeded(request))
  }

  def gotoLogoutSucceeded(result: => Future[Result])(implicit request: RequestHeader, ctx: ExecutionContext): Future[Result] = {
    tokenAccessor.extract(request) foreach idContainer.remove
    result.map(tokenAccessor.delete)
  }
}