If there is no permission policies attached to a role, it fails the
UI with an exception.
Fixes: https://tracker.ceph.com/issues/64588
Signed-off-by: Nizamudeen A <nia@redhat.com>
(cherry picked from commit
5f3f31921c9f3ed909a94f287bfd4cc3f0987649)
setExpandedRow(event: any) {
for (let i = 0; i < this.meta.detail_columns.length; i++) {
let column = this.meta.detail_columns[i];
- let columnDetail = event[column];
+ let columnDetail = event?.[column];
this.expandedRow[column] = this.formatColumnDetails(columnDetail);
}
}
logger.warning('Error listing roles with code %d: %s', code, err)
return []
+ for role in roles:
+ if 'PermissionPolicies' not in role:
+ role['PermissionPolicies'] = []
return roles
def create_role(self, role_name: str, role_path: str, role_assume_policy_doc: str) -> None: