fix for NPE generating ConceptMap spreadsheet

This commit is contained in:
Grahame Grieve 2021-09-29 16:17:52 +10:00
parent 794754a8b0
commit 2df1283a54
1 changed files with 6 additions and 3 deletions

View File

@ -32,9 +32,12 @@ public class ConceptMapSpreadsheetGenerator extends CanonicalSpreadsheetGenerato
}
private void addConceptMapMetadata(Sheet sheet, ConceptMap cm) {
addMetadataRow(sheet, "Source", cm.getSource().primitiveValue());
addMetadataRow(sheet, "Target", cm.getTarget().primitiveValue());
if (cm.hasSource()) {
addMetadataRow(sheet, "Source", cm.getSource().primitiveValue());
}
if (cm.hasTarget()) {
addMetadataRow(sheet, "Target", cm.getTarget().primitiveValue());
}
}
private void renderGroup(ConceptMapGroupComponent grp, int i) {