Titan/webapp/titanembeds/i18n.py

10 lines
207 B
Python

from titanembeds.utils import babel
from flask import request
LANGUAGES = {
'en-US': 'English'
}
@babel.localeselector
def get_locale():
return request.accept_languages.best_match(LANGUAGES.keys())