aboutsummaryrefslogtreecommitdiff
path: root/src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala')
-rw-r--r--src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala b/src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala
index 5135c21..c69fc09 100644
--- a/src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala
+++ b/src/main/scala/xyz/driver/pdsuidomain/entities/export/patient/ExportPatientLabel.scala
@@ -4,7 +4,7 @@ import xyz.driver.pdsuicommon.domain.LongId
import xyz.driver.pdsuicommon.logging._
import xyz.driver.pdsuidomain.entities.{Label, RawPatientLabel}
-final case class ExportPatientLabel(id: LongId[Label], name: String, evidences: List[ExportPatientLabelEvidence])
+final case class ExportPatientLabel(id: LongId[Label], evidences: List[ExportPatientLabelEvidence])
object ExportPatientLabel extends PhiLogging {
@@ -14,15 +14,6 @@ object ExportPatientLabel extends PhiLogging {
}
def fromRaw(labelId: LongId[Label], rawPatientLabels: List[RawPatientLabel]): ExportPatientLabel = {
- val firstLabel = rawPatientLabels.headOption
- if (firstLabel.isEmpty) {
- logger.warn(phi"rawPatientLabels is empty, labelId: $labelId")
- }
-
- ExportPatientLabel(
- id = labelId,
- name = firstLabel.map(_.label).getOrElse(""),
- evidences = rawPatientLabels.map(ExportPatientLabelEvidence.fromRaw)
- )
+ ExportPatientLabel(id = labelId, evidences = rawPatientLabels.map(ExportPatientLabelEvidence.fromRaw))
}
}