Skip to content

Commit 4e41543

Browse files
committed
Fix merge develop into s24-privacy-combined-profile
1 parent aa5803a commit 4e41543

File tree

2 files changed

+36
-11
lines changed

2 files changed

+36
-11
lines changed

Gordon360/Controllers/ScheduleController.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,19 +64,18 @@ public async Task<ActionResult<IEnumerable<CoursesByTermViewModel>>> GetAllCours
6464

6565
// Some users can see schedules of courses taken, as well as taught,
6666
// so check to see if this user can see all courses for this person.
67+
IEnumerable<CoursesByTermViewModel> result;
6768
if ((AuthUtils.GetUsername(User).EqualsIgnoreCase(username)) ||
6869
(accountService.CanISeeStudentSchedule(groups) &&
6970
student != null &&
7071
accountService.CanISeeThisStudent(groups, student)) ||
7172
(accountService.CanISeeAlumniSchedule(groups) && alumni != null))
7273
{
73-
IEnumerable<CoursesByTermViewModel> result = await scheduleService.GetAllCoursesByTermAsync(username);
74-
return Ok(result);
74+
result = await scheduleService.GetAllCoursesByTermAsync(username);
7575
} else
7676
{
7777
// Everyone can see schedules of courses taught.
78-
IEnumerable<CoursesByTermViewModel> result = await scheduleService.GetAllInstructorCoursesByTermAsync(username);
79-
return Ok(result);
78+
result = await scheduleService.GetAllInstructorCoursesByTermAsync(username);
8079
}
8180
var publishedResult = result
8281
.Where(r => string.Equals(r.ShowOnWeb, "B", StringComparison.OrdinalIgnoreCase))

Gordon360/Documentation/Gordon360.xml

Lines changed: 33 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)