Merged in feature/bugfix-course-access-without-mentor (pull request #259)

fix: VV course access without mentor
This commit is contained in:
Daniel Egger 2024-01-06 09:04:15 +00:00
commit 1f24801e72
1 changed files with 3 additions and 1 deletions

View File

@ -102,7 +102,9 @@ const expert = computed(() => {
if (lpQueryResult.course.value?.circle_contact_type === "EXPERT") {
return circleExperts.value[0];
} else if (lpQueryResult.course.value?.circle_contact_type === "LEARNING_MENTOR") {
return mentors.value?.[0].mentor;
if (mentors.value?.length > 0) {
return mentors.value[0].mentor;
}
}
}
return null;