mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-06 05:25:50 +01:00
(refs #33)Use RequestCache instead of AccountService directly.
This commit is contained in:
@@ -22,5 +22,10 @@ trait RequestCache {
|
||||
}
|
||||
}
|
||||
|
||||
def getAccountByMailAddress(mailAddress: String)(implicit context: app.Context): Option[Account] = {
|
||||
context.cache(s"account.${mailAddress}"){
|
||||
new AccountService {}.getAccountByMailAddress(mailAddress)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user