Skip to content

Commit

Permalink
feat: upgrading simple api to drf compatible.
Browse files Browse the repository at this point in the history
  • Loading branch information
awais786 committed Aug 28, 2024
1 parent 34ca712 commit 6b1d7e3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lms/djangoapps/instructor/views/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -2775,7 +2775,11 @@ def post(self, request, course_id):
if not serializer_data.is_valid():
return HttpResponseBadRequest(reason=serializer_data.errors)

# Skipping serializer validation to avoid potential disruptions.
# The API handles numerous input variations, and changes here could introduce breaking issues.

targets = json.loads(request.POST.get("send_to"))

subject = serializer_data.validated_data.get("subject")
message = serializer_data.validated_data.get("message")
# optional, this is a date and time in the form of an ISO8601 string
Expand Down

0 comments on commit 6b1d7e3

Please sign in to comment.