Deprecate request.json property

This commit is contained in:
INADA Naoki 2014-10-15 02:21:52 +09:00
parent cf2a13aaf6
commit 558d7813a0

View file

@ -103,7 +103,9 @@ class Request(RequestBase):
The :meth:`get_json` method should be used instead.
"""
# XXX: deprecate property
from warnings import warn
warn(DeprecationWarning('json is deprecated. '
'Use get_json() instead.'), stacklevel=2)
return self.get_json()
@property