Fix bug where non-instructors couldn't email iCal
This commit is contained in:
parent
0911c9a7e5
commit
edcc8d2ce0
|
@ -334,7 +334,7 @@ class SessionViewSet(Base, List, Retrieve, Create, Update):
|
||||||
|
|
||||||
return response
|
return response
|
||||||
|
|
||||||
@action(detail=True, methods=['post'])
|
@action(detail=True, methods=['post'], permission_classes=[IsAuthenticated])
|
||||||
def email_ical(self, request, pk=None):
|
def email_ical(self, request, pk=None):
|
||||||
session = get_object_or_404(models.Session, id=pk)
|
session = get_object_or_404(models.Session, id=pk)
|
||||||
user = self.request.user
|
user = self.request.user
|
||||||
|
|
Loading…
Reference in New Issue
Block a user