Skip to content
Snippets Groups Projects
Commit a54440b3 authored by tpylak's avatar tpylak
Browse files

minor: remove code duplication

SVN: 9121
parent f98b747d
No related branches found
No related tags found
No related merge requests found
...@@ -39,8 +39,7 @@ public final class SamplePropertyTranslator ...@@ -39,8 +39,7 @@ public final class SamplePropertyTranslator
public final static SampleProperty translate(final SamplePropertyPE samplePropertyPE) public final static SampleProperty translate(final SamplePropertyPE samplePropertyPE)
{ {
final SampleProperty result = new SampleProperty(); final SampleProperty result = new SampleProperty();
result.setValue(samplePropertyPE.getValue() == null ? samplePropertyPE.getVocabularyTerm() result.setValue(samplePropertyPE.tryGetUntypedValue());
.getCode() : samplePropertyPE.getValue());
result result
.setEntityTypePropertyType(SampleTypePropertyTypeTranslator .setEntityTypePropertyType(SampleTypePropertyTypeTranslator
.translate((SampleTypePropertyTypePE) samplePropertyPE .translate((SampleTypePropertyTypePE) samplePropertyPE
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment