Fix mucus.value instead of mucus.computedNfp; additional check for mucus.value

This commit is contained in:
emelko
2018-07-30 16:39:10 +02:00
parent 3a4ce79ea2
commit 20d1af4cdd
+2 -2
View File
@@ -117,8 +117,8 @@ function getLabel(symptomName, symptom) {
}
},
mucus: mucus => {
if (typeof mucus.feeling === 'number' && typeof mucus.texture === 'number') {
let mucusLabel = `${feelingLabels[mucus.feeling]} + ${textureLabels[mucus.texture]} ( ${computeSensiplanMucusLabels[mucus.computedNfp]} )`
if (typeof mucus.feeling === 'number' && typeof mucus.texture === 'number' && typeof mucus.value === 'number') {
let mucusLabel = `${feelingLabels[mucus.feeling]} + ${textureLabels[mucus.texture]} ( ${computeSensiplanMucusLabels[mucus.value]} )`
if (mucus.exclude) mucusLabel = "( " + mucusLabel + " )"
return mucusLabel
}