Skip to content

Commit c023f07

Browse files
authored
Merge pull request #1389 from credebl/fix/all_schemas_selection
Fix crash on all schema view when no organization exists
2 parents ff3c273 + 4816fb6 commit c023f07

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apps/ledger/src/schema/schema.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -649,7 +649,7 @@ export class SchemaService extends BaseService {
649649
const response = await this.schemaRepository.getAllSchemaDetails(schemaSearchCriteria);
650650
const schemasDetails = response?.schemasResult.map((schemaAttributeItem) => {
651651
const attributes = JSON.parse(schemaAttributeItem.attributes);
652-
return { ...schemaAttributeItem, attributes, organizationName: schemaAttributeItem.organisation.name };
652+
return { ...schemaAttributeItem, attributes, organizationName: schemaAttributeItem.organisation?.name || '' };
653653
});
654654

655655
const schemasResponse = {

0 commit comments

Comments
 (0)