From ca1b6a1c38955f7f9e7b388d3dbde6c4e6bdd984 Mon Sep 17 00:00:00 2001 From: kajo24 <67791504+karjo24@users.noreply.github.com> Date: Fri, 15 Nov 2024 15:23:51 +0100 Subject: [PATCH] added missing return after abort (#1407) --- api/courses.go | 1 + 1 file changed, 1 insertion(+) diff --git a/api/courses.go b/api/courses.go index f8c7f924d..4b2c6c4a9 100644 --- a/api/courses.go +++ b/api/courses.go @@ -362,6 +362,7 @@ func (r coursesRoutes) getCourseBySlug(c *gin.Context) { if (course.IsLoggedIn() && tumLiveContext.User == nil) || (course.IsEnrolled() && !tumLiveContext.User.IsEligibleToWatchCourse(course)) { c.AbortWithStatus(http.StatusUnauthorized) + return } user := tumLiveContext.User