Commit a2dcdd7f authored by Jean-Baptiste's avatar Jean-Baptiste

Merge branch '168-str' into 'master'

Resolve "Issue with ManyToManyField while PUTting resource"

Closes #168

See merge request !95
parents 9c944971 e761b742
Pipeline #5236 passed with stage
in 1 minute and 21 seconds
......@@ -270,6 +270,8 @@ class LDPSerializer(HyperlinkedModelSerializer):
class JSonLDPropertyField(ReadOnlyField):
def to_representation(self, instance):
from djangoldp.views import LDPViewSet
if isinstance(instance, QuerySet) or isinstance(instance, Model):
model_class = instance.model
except :
......@@ -299,6 +301,8 @@ class LDPSerializer(HyperlinkedModelSerializer):
return serializer.to_representation(instance)
return instance
field_class = JSonLDPropertyField
field_kwargs = {}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment