diff --git a/src/design/plone/contenttypes/restapi/serializers/dxcontent.py b/src/design/plone/contenttypes/restapi/serializers/dxcontent.py index a87880c6..568cc3a3 100644 --- a/src/design/plone/contenttypes/restapi/serializers/dxcontent.py +++ b/src/design/plone/contenttypes/restapi/serializers/dxcontent.py @@ -51,7 +51,6 @@ def __call__(self, version=None, include_items=True): @adapter(IDexterityContainer, IDesignPloneContenttypesLayer) class SerializeFolderToJson(BaseFolderSerializer, MetaTypeSerializer): def __call__(self, version=None, include_items=True): - result = super(SerializeFolderToJson, self).__call__( version=version, include_items=include_items ) diff --git a/src/design/plone/contenttypes/restapi/services/types/get.py b/src/design/plone/contenttypes/restapi/services/types/get.py index c18ce171..206dd81b 100644 --- a/src/design/plone/contenttypes/restapi/services/types/get.py +++ b/src/design/plone/contenttypes/restapi/services/types/get.py @@ -185,25 +185,25 @@ def customize_venue_schema(self, result): } if "city" in result["properties"]: if not result["properties"]["city"].get("default", ""): - result["properties"]["city"]["default"] = ( - api.portal.get_registry_record( - "city", interface=IGeolocationDefaults - ) + result["properties"]["city"][ + "default" + ] = api.portal.get_registry_record( + "city", interface=IGeolocationDefaults ) if "zip_code" in result["properties"]: if not result["properties"]["zip_code"].get("default", ""): - result["properties"]["zip_code"]["default"] = ( - api.portal.get_registry_record( - "zip_code", interface=IGeolocationDefaults - ) + result["properties"]["zip_code"][ + "default" + ] = api.portal.get_registry_record( + "zip_code", interface=IGeolocationDefaults ) if "street" in result["properties"]: if not result["properties"]["street"].get("default", ""): - result["properties"]["street"]["default"] = ( - api.portal.get_registry_record( - "street", interface=IGeolocationDefaults - ) + result["properties"]["street"][ + "default" + ] = api.portal.get_registry_record( + "street", interface=IGeolocationDefaults ) if "geolocation" in result["properties"]: diff --git a/src/design/plone/contenttypes/upgrades/to_730x.py b/src/design/plone/contenttypes/upgrades/to_730x.py index 5ec2ca47..5d5dcf3a 100644 --- a/src/design/plone/contenttypes/upgrades/to_730x.py +++ b/src/design/plone/contenttypes/upgrades/to_730x.py @@ -96,7 +96,11 @@ def to_7304(context): def to_7305(context): mapping = SUBFOLDERS_MAPPING["Servizio"] - mapping = [folder for folder in mapping.get('content') if folder["id"] == "modulistica"][0] # noqa + mapping = [ + folder for folder in mapping.get("content") if folder["id"] == "modulistica" + ][ + 0 + ] # noqa brains = api.content.find(portal_type="Servizio") tot = len(brains) i = 0