In order to cache actions per label and language for a given number of seconds, I wrote the following helper method (where label, is the name I give to my action):
Maybe the problem is in the getLanguage method. Try this, as recommended by the docs:
def getLanguage(request: RequestHeader): String = {
request.acceptLanguages
.map(_.code)
.headOption
.getOrElse(helpers.LanguageHelpers.FRENCH)
}
Also, take a look at Controller.request2lang() method and see if it could be helpful to you.