// Similar method to Index(), but to provide for filtered CourseIndexModel view by Instructor UserId.
        public IActionResult MyCourses(string userId)
        {
            var myCourses = _courseService.GetByInstructor(userId)
                            .Select(c => new CourseListItem
            {
                Id         = c.Id,
                Instructor = c.Instructor,
                CourseName = c.CourseName,
            });
            var model = new CourseIndexModel
            {
                CourseIndexList = myCourses
            };

            return(View(model));
        }