fix(applications): 修改attrs不能为null (#5171)

Co-authored-by: Bai <bugatti_it@163.com>
This commit is contained in:
fit2bot
2020-12-04 10:24:10 +08:00
committed by GitHub
parent 662c9092dc
commit 75ef413ea5

View File

@@ -27,10 +27,7 @@ class ApplicationSerializer(BulkOrgResourceModelSerializer):
]
def create(self, validated_data):
attrs = validated_data.pop('attrs', {})
instance = super().create(validated_data)
instance.attrs = attrs
instance.save()
return instance
def update(self, instance, validated_data):