diff --git a/news/1696.bugfix b/news/1696.bugfix new file mode 100644 index 0000000000..39b4c8adee --- /dev/null +++ b/news/1696.bugfix @@ -0,0 +1 @@ +Undeprecate comma separated expansion parameters (that were deprecated in plone.restapi 8) @tisto \ No newline at end of file diff --git a/src/plone/restapi/serializer/expansion.py b/src/plone/restapi/serializer/expansion.py index b7d10fa303..6c0db68267 100644 --- a/src/plone/restapi/serializer/expansion.py +++ b/src/plone/restapi/serializer/expansion.py @@ -1,19 +1,14 @@ from plone.restapi.interfaces import IExpandableElement from zope.component import getAdapters -import warnings - def expandable_elements(context, request): """Returns a dict containing all expandable elements.""" expands = request.form.get("expand", []) if isinstance(expands, str): if "," in expands: - # deprecated use of expands (with commas) - warnings.warn( - "``expand`` as a string parameter separated with commas is deprecated and will be removed in plone.restapi 9.0. Use ``expand:list`` instead.", - DeprecationWarning, - ) + # use of expands (with commas) was deprecated in plone.restapi 8 + # undeprecated with plone.restapi 9 expands = expands.split(",") else: # allow still the use of non marked :list parameters present