Remove Py2/Py3 difference from Example

`print` is available as a function on every supported version of Python (2.7+)
This commit is contained in:
Carlton Gibson 2016-05-25 15:10:53 +02:00
parent 9b56dda918
commit c0aed19cb0

View File

@ -452,7 +452,7 @@ To do so, open the Django shell, using `python manage.py shell`, then import the
>>> from myapp.serializers import AccountSerializer >>> from myapp.serializers import AccountSerializer
>>> serializer = AccountSerializer() >>> serializer = AccountSerializer()
>>> print repr(serializer) # Or `print(repr(serializer))` in Python 3.x. >>> print(repr(serializer))
AccountSerializer(): AccountSerializer():
id = IntegerField(label='ID', read_only=True) id = IntegerField(label='ID', read_only=True)
name = CharField(allow_blank=True, max_length=100, required=False) name = CharField(allow_blank=True, max_length=100, required=False)