aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Barrett2012-09-19 08:05:16 -0700
committerMichael Barrett2012-09-19 08:05:16 -0700
commit943bc073d986b1d5bc10c6d17d3601d4311c3681 (patch)
treeb2a9b319eaa8f976bcea3d74324c162fd2234e43
parent0fc5a49a114ca65aab90dcf039da1569dde3c499 (diff)
downloaddjango-rest-framework-943bc073d986b1d5bc10c6d17d3601d4311c3681.tar.bz2
Fixing Issue #265.
https://github.com/tomchristie/django-rest-framework/issues/265
-rw-r--r--djangorestframework/serializer.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/djangorestframework/serializer.py b/djangorestframework/serializer.py
index 3f05903b..5d77c461 100644
--- a/djangorestframework/serializer.py
+++ b/djangorestframework/serializer.py
@@ -182,7 +182,7 @@ class Serializer(object):
else:
depth = self.depth - 1
- if any([obj is elem for elem in self.stack]):
+ if obj in self.stack:
return self.serialize_recursion(obj)
else:
stack = self.stack[:]