public async Task GetEnrollmentAsync(params string[] options) { var channelConfig = await ConfigurationService.ReadChannelAsync(Context.Channel.Id); List <CourseModel> courses; switch (options.Length) { case 0: await Context.Channel.SendMessageAsync( "No results were fetched because no parameters were specified."); return; case 1: courses = await EnrollmentService.GetCoursesById(channelConfig.Semester, options[0], ""); break; case 2: courses = await EnrollmentService.GetCoursesById(channelConfig.Semester, options[0], options[1]); break; default: return; } var table = new PrettyTable <CourseModel> { Data = courses }; table.AddColumn("Catalog", x => x.Department + " " + x.CatalogNumber); table.AddColumn("Section", x => x.SectionNumber); table.AddColumn("Title", x => x.Name); table.AddColumn("Instructor", x => x.Instructor); table.AddColumn("Enrollment", x => x.Enrolled + "/" + x.Size); await SplitAndSendMessageAsync(Context.Channel, "```" + table.BuildTable() + "```"); }