Skip to content

Commit

Permalink
added missing return after abort
Browse files Browse the repository at this point in the history
  • Loading branch information
karjo24 committed Nov 15, 2024
1 parent c6c3f16 commit c74aa75
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions api/courses.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit c74aa75

Please sign in to comment.