fix(functionality): Fix search so results are rendered with proper heading

This commit is contained in:
Simon Chen
2018-11-27 14:47:11 -05:00
parent a5a62922b5
commit f779e7fd35

View File

@@ -86,7 +86,12 @@ const fetchMatchingUserGrades = (courseId, searchText, cohort, track) => (
return LmsApiService.fetchGradebookData(courseId, searchText, cohort, track)
.then(response => response.data)
.then((data) => {
dispatch(gotGrades(data.results.sort(sortAlphaAsc), cohort, track));
dispatch(gotGrades(
data.results.sort(sortAlphaAsc),
cohort,
track,
headingMapper.all(dispatch, data.results[0]),
));
dispatch(finishedFetchingGrades());
})
.catch(() => {