Esempio n. 1
0
        public static async Task <string> ToUserLocale(this string text, IDialogContext context)
        {
            context.UserData.TryGetValue(AppSettings.UserLanguageKey, out string userLanguageCode);

            text = await TranslateService.TranslateAsync(text, AppSettings.DefaultLanguage, userLanguageCode);

            return(text);
        }