Blog.Logic.Core.TagsLogic.GetTagsByName C# (CSharp) Метод

GetTagsByName() публичный Метод

public GetTagsByName ( string tagName ) : List
tagName string
Результат List
        public List<Tag> GetTagsByName(string tagName)
        {
            var tags = new List<Tag>();
            try
            {
                var db = _tagRepository.Find(a => a.TagName.Contains(tagName), true).ToList();
                db.ForEach(a => tags.Add(TagMapper.ToDto(a)));
            }
            catch (Exception ex)
            {
                throw new BlogException(ex.Message, ex.InnerException);
            }
            return tags;
        }