Skip to content

Commit

Permalink
fix: remove instructor info serializer validation (#34802)
Browse files Browse the repository at this point in the history
  • Loading branch information
rayzhou-bit authored May 16, 2024
1 parent 9fbc6e3 commit 0fd3bde
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

class InstructorInfoSerializer(serializers.Serializer):
""" Serializer for instructor info """
name = serializers.CharField(allow_blank=True)
name = serializers.CharField(allow_blank=True, required=False)
title = serializers.CharField(allow_blank=True, required=False)
organization = serializers.CharField(allow_blank=True, required=False)
image = serializers.CharField(allow_blank=True, required=False)
Expand All @@ -18,7 +18,7 @@ class InstructorInfoSerializer(serializers.Serializer):

class InstructorsSerializer(serializers.Serializer):
""" Serializer for instructors """
instructors = InstructorInfoSerializer(many=True, allow_empty=True)
instructors = InstructorInfoSerializer(many=True, allow_empty=True, allow_null=True, required=False)


class CourseDetailsSerializer(serializers.Serializer):
Expand Down

0 comments on commit 0fd3bde

Please sign in to comment.