fix: isadmin update causes duplicate fetch for courses

This commit is contained in:
Rotimi Best
2024-05-24 20:30:45 +01:00
parent 92bc3eb545
commit 5efc1e1bda
2 changed files with 32 additions and 1 deletions
@@ -8,7 +8,7 @@ export async function fetchCourses(profileId, orgId) {
const match = {};
// Filter by profile_id if role isn't admin within organization
if (!get(isOrgAdmin)) {
match.profile_id = profileId;
match.member_profile_id = profileId;
}
// Gets courses for a particular organisation where the current logged in user is a groupmember