Merge pull request #1780 from pateljannat/issues-139

fix: moderators should be able to access unpublished courses
This commit is contained in:
Jannat Patel
2025-10-14 20:46:14 +05:30
committed by GitHub
2 changed files with 7 additions and 2 deletions

View File

@@ -144,7 +144,12 @@ watch(
)
watch(course, () => {
if (!isInstructor() && !course.data?.published && !course.data?.upcoming) {
if (
!isInstructor() &&
!user.data?.is_moderator &&
!course.data?.published &&
!course.data?.upcoming
) {
router.push({
name: 'Courses',
})