diff --git a/src/npc/startingGirls/editFamily.js b/src/npc/startingGirls/editFamily.js index 8a8c0f1454363159fd6c7fb942844f84db783bb6..40522e45870e6d5484151c85c01a49a5f60e606b 100644 --- a/src/npc/startingGirls/editFamily.js +++ b/src/npc/startingGirls/editFamily.js @@ -261,10 +261,13 @@ App.Intro.editFamily = function(slave) { const div = document.createElement("div"); const linkArray = []; - div.append(`${slave.slaveName} is the mother of these children: `); - + const children = App.StartingGirls.listOfSlavesWithParent("mother", slave.ID); const nameEl = makeElWithID("motheredNames", "span"); - nameEl.append(App.StartingGirls.listOfSlavesWithParent("mother", slave.ID) || "None.", " "); + if (children) { + nameEl.append(`${slave.slaveName} is the mother of these children: ${children}. Add: `); + } else { + nameEl.append(`${slave.slaveName} is not a mother to any children yet. Add: `); + } div.append(nameEl); linkArray.push( @@ -328,10 +331,13 @@ App.Intro.editFamily = function(slave) { const div = document.createElement("div"); const linkArray = []; - div.append(`${slave.slaveName} is the father of these children: `); - + const children = App.StartingGirls.listOfSlavesWithParent("father", slave.ID); const nameEl = makeElWithID("fatheredNames", "span"); - nameEl.append(App.StartingGirls.listOfSlavesWithParent("father", slave.ID) || "None.", " "); + if (children) { + nameEl.append(`${slave.slaveName} is the father of these children: ${children}. Add: `); + } else { + nameEl.append(`${slave.slaveName} is not a father to any children yet. Add: `); + } div.append(nameEl); linkArray.push(