Skip to content

Commit

Permalink
Merge pull request #1501 from bcgov/fix/EDX-1618
Browse files Browse the repository at this point in the history
EDX-1618 - Checks for adminUsers on all users instead of filteredUsers
  • Loading branch information
SodhiA1 authored Jul 13, 2023
2 parents 015aed0 + 3cf3472 commit 3106b57
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ export default {
computed: {
...mapState(edxStore, ['districtRoles', 'districtRolesCopy']),
hasAdminUsers() {
return this.filteredUsers.filter(user => {
return this.users.filter(user => {
return user.edxUserDistricts.some(district => district.edxUserDistrictRoles.some(role => role.edxRoleCode === ROLE.EDX_DISTRICT_ADMIN));
})?.length > 0;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ export default {
...mapState(appStore, ['schoolMap']),
...mapState(edxStore, ['schoolRoles','schoolRolesCopy']),
hasAdminUsers() {
return this.filteredUsers.filter(user => {
return this.users.filter(user => {
return user.edxUserSchools.some(school => school.edxUserSchoolRoles.some(role => role.edxRoleCode === ROLE.EDX_SCHOOL_ADMIN));
})?.length > 0;
}
Expand Down

0 comments on commit 3106b57

Please sign in to comment.