public ActionResult Index(string seName) { var skill = _skillService.GetBySeName(seName); if (skill == null) { return(InvokeHttp404()); } var model = new SkillPageModel() { Description = skill.Description, Name = skill.Name, Slug = seName }; //check if the logged in user has this skill? if (!_workContext.CurrentCustomer.IsGuest()) { var userSkill = _userSkillService.FirstOrDefault( x => x.UserId == _workContext.CurrentCustomer.Id && x.SkillId == skill.Id); if (userSkill != null) { model.UserSkillId = userSkill.Id; } } return(View("mobSocial/Skills/Single", model)); }