/// <summary>Fills the list of words with translation.</summary> /// <param name="material">Material.</param> /// <returns>List of vocabulary words.</returns> private async Task <List <VocabWord> > FillVocabWordsByMaterial(Material material) { var arrayOfWords = material.File.Words == null ? new string[0] : material.File.Words.Select(n => n.TheWord).ToArray(); return(await _vocabularyService.FillVocabByWords(arrayOfWords, User.Identity.GetUserId <int>())); }