Skip to content

Commit

Permalink
fixed sitemap for proxy nodes (KKI, 2)
Browse files Browse the repository at this point in the history
  • Loading branch information
drfho authored Sep 4, 2024
1 parent 1a62c96 commit afcf696
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Products/zms/rest_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,11 @@ def get_attrs(node):
data['has_portal_clients'] = node.getPortalClients() != []
general_keys = data.keys()
obj_attrs = node.getObjAttrs()
try:
metaobj_attrs = node.getMetaobjManager().getMetaobjAttrs(node.meta_id)
except:
# In case node is a ZMSProxy object:
if hasattr(node,'proxy'):
metaobj_attrs = node.proxy.getMetaobjManager().getMetaobjAttrs(node.meta_id)
data['meta_id'] = 'ZMSLinkElement'
else:
metaobj_attrs = node.getMetaobjManager().getMetaobjAttrs(node.meta_id)
for metaobj_attr in metaobj_attrs:
id = metaobj_attr['id']
if id in obj_attrs and not id in general_keys:
Expand Down

0 comments on commit afcf696

Please sign in to comment.