diff --git a/src/art/vector/VectorArtJS.js b/src/art/vector/VectorArtJS.js
index 3da76328829c64dffd0f46ba2d17538f9f5c38e3..5295d7e10723260e28f416d0ee354a07e32acc0b 100644
--- a/src/art/vector/VectorArtJS.js
+++ b/src/art/vector/VectorArtJS.js
@@ -1,4 +1,4 @@
-window.VectorArt = (function() {
+window.VectorArt = (function () {
 	"use strict";
 	let V, T, slave;
 	let r;
@@ -2679,7 +2679,7 @@ window.VectorArt = (function() {
 	return VectorArt;
 })();
 
-window.LegacyVectorArt = function(slave, artSize) {
+window.LegacyVectorArt = function (slave, artSize) {
 	const filePath = "'resources/vector";
 	const skinFilePath = `${filePath}/body/white`;
 	const wearingLatex = slave.clothes === "a Fuckdoll suit" || slave.clothes === "restrictive latex" || slave.clothes === "a latex catsuit";
diff --git a/src/js/DefaultRules.js b/src/js/DefaultRules.js
index 90ed3d4ce5e15732d65c95663fee18ee48d31239..c94323529c1f644a6d2bd5da1cac1d911c4dd383 100644
--- a/src/js/DefaultRules.js
+++ b/src/js/DefaultRules.js
@@ -1,6 +1,6 @@
 // this code applies RA rules onto slaves
 
-window.DefaultRules = (function() {
+window.DefaultRules = (function () {
 	"use strict";
 	let V;
 	let r;
@@ -1353,7 +1353,7 @@ window.DefaultRules = (function() {
 				}
 			}
 			if (_priorities.length > 1) {
-				_priorities = _priorities.sort(function(a, b) {
+				_priorities = _priorities.sort(function (a, b) {
 					if (a.weight > b.weight) {
 						return -1;
 					}
diff --git a/src/js/quickListJS.js b/src/js/quickListJS.js
index 6d90ef8373ada8fbd8a48b22491138a659782ece..8ac22f3e4c859dbdd3731ec668ec01de73d915d8 100644
--- a/src/js/quickListJS.js
+++ b/src/js/quickListJS.js
@@ -1,35 +1,36 @@
-window.sortDomObjects = function(objects, attrName, reverse = 0) {
+window.sortDomObjects = function (objects, attrName, reverse = 0) {
 	reverse = (reverse) ? -1 : 1;
 
 	function sortingByAttr(a, b) {
 		let aVal = a.getAttribute(attrName);
 		let bVal = b.getAttribute(attrName);
 		let aInt = parseInt(aVal);
-		if (!isNaN(aInt))
+		if (!isNaN(aInt)) {
 			return ((parseInt(bVal) - aInt) * reverse);
-		else if (bVal > aVal)
+		} else if (bVal > aVal) {
 			return -1 * reverse;
+		}
 		return ((aVal === bVal) ? 0 : 1) * reverse;
 	}
 	return objects.toArray().sort(sortingByAttr);
 };
 
-window.sortButtonsByDevotion = function() {
+window.sortButtonsByDevotion = function () {
 	let $sortedButtons = $('#qlWrapper button').remove();
 	$sortedButtons = sortDomObjects($sortedButtons, 'data-devotion');
 	$($sortedButtons).appendTo($('#qlWrapper'));
 	quickListBuildLinks();
 };
 
-window.sortButtonsByTrust = function() {
+window.sortButtonsByTrust = function () {
 	let $sortedButtons = $('#qlWrapper button').remove();
 	$sortedButtons = sortDomObjects($sortedButtons, 'data-trust');
 	$($sortedButtons).appendTo($('#qlWrapper'));
 	quickListBuildLinks();
 };
 
-window.quickListBuildLinks = function() {
-	$("[data-scroll-to]").click(function() {
+window.quickListBuildLinks = function () {
+	$("[data-scroll-to]").click(function () {
 		let $this = $(this),
 			$toElement = $this.attr('data-scroll-to');
 		// note the * 1 enforces $offset to be an integer, without
@@ -43,31 +44,31 @@ window.quickListBuildLinks = function() {
 	});
 };
 
-window.sortIncubatorPossiblesByName = function() {
+window.sortIncubatorPossiblesByName = function () {
 	let $sortedIncubatorPossibles = $('#qlIncubator div.possible').detach();
 	$sortedIncubatorPossibles = sortDomObjects($sortedIncubatorPossibles, 'data-name');
 	$($sortedIncubatorPossibles).appendTo($('#qlIncubator'));
 };
 
-window.sortIncubatorPossiblesByPregnancyWeek = function() {
+window.sortIncubatorPossiblesByPregnancyWeek = function () {
 	let $sortedIncubatorPossibles = $('#qlIncubator div.possible').detach();
 	$sortedIncubatorPossibles = sortDomObjects($sortedIncubatorPossibles, 'data-preg-week');
 	$($sortedIncubatorPossibles).appendTo($('#qlIncubator'));
 };
 
-window.sortIncubatorPossiblesByPregnancyCount = function() {
+window.sortIncubatorPossiblesByPregnancyCount = function () {
 	let $sortedIncubatorPossibles = $('#qlIncubator div.possible').detach();
 	$sortedIncubatorPossibles = sortDomObjects($sortedIncubatorPossibles, 'data-preg-count');
 	$($sortedIncubatorPossibles).appendTo($('#qlIncubator'));
 };
 
-window.sortIncubatorPossiblesByReservedSpots = function() {
+window.sortIncubatorPossiblesByReservedSpots = function () {
 	let $sortedIncubatorPossibles = $('#qlIncubator div.possible').detach();
 	$sortedIncubatorPossibles = sortDomObjects($sortedIncubatorPossibles, 'data-reserved-spots');
 	$($sortedIncubatorPossibles).appendTo($('#qlIncubator'));
 };
 
-window.sortIncubatorPossiblesByPreviousSort = function() {
+window.sortIncubatorPossiblesByPreviousSort = function () {
 	let sort = State.variables.sortIncubatorList;
 	if ('unsorted' !== sort) {
 		if ('Name' === sort) {
@@ -82,31 +83,31 @@ window.sortIncubatorPossiblesByPreviousSort = function() {
 	}
 };
 
-window.sortNurseryPossiblesByName = function() {
+window.sortNurseryPossiblesByName = function () {
 	let $sortedNurseryPossibles = $('#qlNursery div.possible').detach();
 	$sortedNurseryPossibles = sortDomObjects($sortedNurseryPossibles, 'data-name');
 	$($sortedNurseryPossibles).appendTo($('#qlNursery'));
 };
 
-window.sortNurseryPossiblesByPregnancyWeek = function() {
+window.sortNurseryPossiblesByPregnancyWeek = function () {
 	let $sortedNurseryPossibles = $('#qlNursery div.possible').detach();
 	$sortedNurseryPossibles = sortDomObjects($sortedNurseryPossibles, 'data-preg-week');
 	$($sortedNurseryPossibles).appendTo($('#qlNursery'));
 };
 
-window.sortNurseryPossiblesByPregnancyCount = function() {
+window.sortNurseryPossiblesByPregnancyCount = function () {
 	let $sortedNurseryPossibles = $('#qlNursery div.possible').detach();
 	$sortedNurseryPossibles = sortDomObjects($sortedNurseryPossibles, 'data-preg-count');
 	$($sortedNurseryPossibles).appendTo($('#qlNursery'));
 };
 
-window.sortNurseryPossiblesByReservedSpots = function() {
+window.sortNurseryPossiblesByReservedSpots = function () {
 	let $sortedNurseryPossibles = $('#qlNursery div.possible').detach();
 	$sortedNurseryPossibles = sortDomObjects($sortedNurseryPossibles, 'data-reserved-spots');
 	$($sortedNurseryPossibles).appendTo($('#qlNursery'));
 };
 
-window.sortNurseryPossiblesByPreviousSort = function() {
+window.sortNurseryPossiblesByPreviousSort = function () {
 	let sort = State.variables.sortNurseryList;
 	if ('unsorted' !== sort) {
 		if ('Name' === sort) {
diff --git a/src/js/removeActiveSlave.js b/src/js/removeActiveSlave.js
index d40f8b2ef19fd04320f2185b077241c728d11776..d07be0a9658e3c963785c8049b769baa07f502df 100644
--- a/src/js/removeActiveSlave.js
+++ b/src/js/removeActiveSlave.js
@@ -125,7 +125,7 @@ window.removeActiveSlave = function removeActiveSlave() {
 		}
 
 		if (Array.isArray(V.personalAttention)) {
-			const _rasi = V.personalAttention.findIndex(function(s) {return s.ID === AS_ID;});
+			const _rasi = V.personalAttention.findIndex(function (s) { return s.ID === AS_ID; });
 			if (_rasi !== -1) {
 				V.personalAttention.deleteAt(_rasi);
 				if (V.personalAttention.length === 0) {
@@ -195,7 +195,7 @@ window.removeActiveSlave = function removeActiveSlave() {
 			}
 		}
 
-		const _geneIndex = V.genePool.findIndex(function(s) {return s.ID === AS_ID;});
+		const _geneIndex = V.genePool.findIndex(function (s) { return s.ID === AS_ID; });
 		if (_geneIndex !== -1) {
 			let keep = false;
 			if (V.traitor !== 0) {
@@ -335,7 +335,7 @@ window.removeNonNGPSlave = function removeNonNGPSlave(removedSlave) {
 			}
 		});
 
-		const _geneIndex = V.genePool.findIndex(function(s) {return s.ID === ID;});
+		const _geneIndex = V.genePool.findIndex(function (s) { return s.ID === ID; });
 		if (_geneIndex !== -1) {
 			let keep = false;
 			if (isImpregnatedBy(V.PC, removedSlave)) {
diff --git a/src/js/slaveGenerationJS.js b/src/js/slaveGenerationJS.js
index e05b2e9cb99d73328b7e34e0c12d72bcd9efe28b..5bb707929cbc3e32a843a4936587acd03d7cfdb2 100644
--- a/src/js/slaveGenerationJS.js
+++ b/src/js/slaveGenerationJS.js
@@ -28,6 +28,7 @@ window.raceToNationality = function raceToNationality(slave) {
  * @param {string | Object} race
  * @param {boolean} male
  * @param {undefined} [filter] Default: allow all
+ * @returns {string}
  */
 window.generateName = function generateName(nationality, race, male, filter = _.stubTrue) {
 	const lookup = (male ? setup.malenamePoolSelector : setup.namePoolSelector);
@@ -45,7 +46,8 @@ window.generateName = function generateName(nationality, race, male, filter = _.
  * @param {string | number} nationality
  * @param {any} race
  * @param {any} male
- * @param {() => true} [filter]  Default: allow all
+ * @param {Function} [filter]  Default: allow all
+ * @returns {string}
  */
 window.generateSurname = function generateSurname(nationality, race, male, filter = _.stubTrue) {
 	const result = jsEither(
@@ -1530,7 +1532,7 @@ window.generatePronouns = function generatePronouns(slave) {
 /**
  * @param {App.Entity.SlaveState} slave
  */
-window.generatePuberty = function(slave) {
+window.generatePuberty = function (slave) {
 	if ((slave.ovaries === 1 || slave.mpreg === 1) && slave.physicalAge >= slave.pubertyAgeXX) {
 		slave.pubertyXX = 1;
 	} else {
@@ -1546,7 +1548,7 @@ window.generatePuberty = function(slave) {
 /**
  * @param {App.Entity.SlaveState} slave
  */
-window.ageImplantAdjustment = function(slave) {
+window.ageImplantAdjustment = function (slave) {
 	if (slave.visualAge > 80) {
 		slave.visualAge -= 40;
 	} else if (slave.visualAge >= 70) {
diff --git a/src/js/slaveStatsChecker.js b/src/js/slaveStatsChecker.js
index b9c0d306b971023d5af65e6f0079d643d150a44d..905d4f8bd54f621d037ba1ce660a413c28180391 100644
--- a/src/js/slaveStatsChecker.js
+++ b/src/js/slaveStatsChecker.js
@@ -1,4 +1,4 @@
-window.SlaveStatsChecker = (function() {
+window.SlaveStatsChecker = (function () {
 	return {
 		checkForLisp: hasLisp,
 		isModded: isModded,
@@ -177,7 +177,7 @@ window.SlaveStatsChecker = (function() {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isSlim = function(slave) {
+window.isSlim = function (slave) {
 	let slim = false;
 	const ArcologyZero = State.variables.arcologies[0];
 
@@ -209,7 +209,7 @@ window.isSlim = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {number}
  */
-window.slimPass = function(slave) {
+window.slimPass = function (slave) {
 	let slimPass = 0;
 	const ArcologyZero = State.variables.arcologies[0];
 
@@ -238,7 +238,7 @@ window.slimPass = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isStacked = function(slave) {
+window.isStacked = function (slave) {
 	return (slave.butt > 4) && (slave.boobs > 800);
 };
 
@@ -246,7 +246,7 @@ window.isStacked = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isXY = function(slave) {
+window.isXY = function (slave) {
 	return (slave.dick > 0);
 };
 
@@ -254,7 +254,7 @@ window.isXY = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isYoung = function(slave) {
+window.isYoung = function (slave) {
 	return (slave.visualAge < 30);
 };
 
@@ -262,7 +262,7 @@ window.isYoung = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isPreg = function(slave) {
+window.isPreg = function (slave) {
 	return ((slave.bellyPreg >= 5000) || (slave.bellyImplant >= 5000));
 };
 
@@ -270,7 +270,7 @@ window.isPreg = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isNotPreg = function(slave) {
+window.isNotPreg = function (slave) {
 	return (!isPreg(slave) && (slave.belly < 100) && (slave.weight < 30) && !setup.fakeBellies.includes(slave.bellyAccessory));
 };
 
@@ -278,7 +278,7 @@ window.isNotPreg = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isPure = function(slave) {
+window.isPure = function (slave) {
 	return ((slave.boobsImplant === 0) && (slave.buttImplant === 0) && (slave.waist >= -95) && (slave.lipsImplant === 0) && (slave.faceImplant < 30) && (slave.bellyImplant === -1) && (Math.abs(slave.shouldersImplant) < 2) && (Math.abs(slave.hipsImplant) < 2));
 };
 
@@ -286,7 +286,7 @@ window.isPure = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isSurgicallyImproved = function(slave) {
+window.isSurgicallyImproved = function (slave) {
 	return ((slave.boobsImplant > 0) && (slave.buttImplant > 0) && (slave.waist < -10) && (slave.lipsImplant > 0));
 };
 
@@ -294,7 +294,7 @@ window.isSurgicallyImproved = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isFullyPotent = function(slave) {
+window.isFullyPotent = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.dick > 0 && slave.balls > 0 && slave.ballType !== "sterile" && slave.hormoneBalance < 100 && slave.drugs !== "hormone blockers") {
@@ -307,7 +307,7 @@ window.isFullyPotent = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canGetPregnant = function(slave) {
+window.canGetPregnant = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.preg === -1) { /* contraceptives check */
@@ -327,7 +327,7 @@ window.canGetPregnant = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.isFertile = function(slave) {
+window.isFertile = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -375,7 +375,7 @@ window.isFertile = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canAchieveErection = function(slave) {
+window.canAchieveErection = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.dick <= 0) {
@@ -384,13 +384,13 @@ window.canAchieveErection = function(slave) {
 		return true;
 	} else if (slave.dick > 7) {
 		return false;
-	} else if (slave.aphrodisiacs > 1 || (slave.inflationType == "aphrodisiac" && slave.inflation >= 2)) {
+	} else if (slave.aphrodisiacs > 1 || (slave.inflationType === "aphrodisiac" && slave.inflation >= 2)) {
 		return true;
 	} else if (slave.ballType === "sterile") {
 		return false;
 	} else if ((slave.balls > 0 ? slave.hormoneBalance < 100 : slave.hormoneBalance <= -100) && slave.drugs !== "hormone blockers") {
 		return true;
-	} else if (slave.aphrodisiacs > 0 || slave.inflationType == "aphrodisiac") {
+	} else if (slave.aphrodisiacs > 0 || slave.inflationType === "aphrodisiac") {
 		return true;
 	}
 	return false;
@@ -400,7 +400,7 @@ window.canAchieveErection = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canPenetrate = function(slave) {
+window.canPenetrate = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (!canAchieveErection(slave)) {
@@ -417,7 +417,7 @@ window.canPenetrate = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canSee = function(slave) {
+window.canSee = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -428,7 +428,7 @@ window.canSee = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canHear = function(slave) {
+window.canHear = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -439,7 +439,7 @@ window.canHear = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canSmell = function(slave) {
+window.canSmell = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -450,7 +450,7 @@ window.canSmell = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canTaste = function(slave) {
+window.canTaste = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -461,7 +461,7 @@ window.canTaste = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canWalk = function(slave) {
+window.canWalk = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.amp === 1) {
@@ -494,7 +494,7 @@ window.canWalk = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canTalk = function(slave) {
+window.canTalk = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.accent > 2) {
@@ -519,7 +519,7 @@ window.canTalk = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canDoAnal = function(slave) {
+window.canDoAnal = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.chastityAnus === 1) {
@@ -532,7 +532,7 @@ window.canDoAnal = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.canDoVaginal = function(slave) {
+window.canDoVaginal = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.vagina < 0) {
@@ -547,7 +547,7 @@ window.canDoVaginal = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooFatSlave = function(slave) {
+window.tooFatSlave = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.weight > 190 + (slave.muscles / 5) && slave.physicalAge >= 18) {
@@ -566,7 +566,7 @@ window.tooFatSlave = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooBigBreasts = function(slave) {
+window.tooBigBreasts = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.boobs > 30000 + (slave.muscles * 100) && slave.physicalAge >= 18) {
@@ -585,7 +585,7 @@ window.tooBigBreasts = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooBigBelly = function(slave) {
+window.tooBigBelly = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.belly >= 450000 + (slave.muscles * 2000) && slave.physicalAge >= 18) {
@@ -604,7 +604,7 @@ window.tooBigBelly = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooBigBalls = function(slave) {
+window.tooBigBalls = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.balls >= 30 + (slave.muscles * .3) && slave.physicalAge <= 3) {
@@ -621,7 +621,7 @@ window.tooBigBalls = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooBigDick = function(slave) {
+window.tooBigDick = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.dick >= 20 + (slave.muscles * .1) && slave.physicalAge <= 3 && slave.dick !== 0) {
@@ -638,7 +638,7 @@ window.tooBigDick = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.tooBigButt = function(slave) {
+window.tooBigButt = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.butt > 10 && slave.physicalAge <= 3) {
diff --git a/src/js/storyJS.js b/src/js/storyJS.js
index feee5723793dde47d5f952897c5398661fce146d..a58bc99bbe522b7a4e5f52977ff827be403c3447 100644
--- a/src/js/storyJS.js
+++ b/src/js/storyJS.js
@@ -8,7 +8,7 @@
  * @param {number} maxValue
  * @returns {number}
  */
-window.variableAsNumber = function(x, defaultValue = 0, minValue, maxValue) {
+window.variableAsNumber = function (x, defaultValue = 0, minValue, maxValue) {
 	x = Number(x);
 	if (isNaN(x)) {
 		return defaultValue;
@@ -26,7 +26,7 @@ window.variableAsNumber = function(x, defaultValue = 0, minValue, maxValue) {
  * @param {App.Entity.SlaveState} slave
  * @return {boolean}
  */
-window.isSexuallyPure = function(slave) {
+window.isSexuallyPure = function (slave) {
 	if (!slave) {
 		return null;
 	}
@@ -34,7 +34,7 @@ window.isSexuallyPure = function(slave) {
 };
 
 if (typeof interpolate === "undefined") {
-	const interpolate = function(x0, y0, x1, y1, x) {
+	const interpolate = function (x0, y0, x1, y1, x) {
 		if (x <= x0) {
 			return y0;
 		} else if (x >= x1) {
@@ -51,7 +51,7 @@ if (typeof interpolate === "undefined") {
  * @param {any} val
  * @returns {any[]}
  */
-window.removeFromArray = function(arr, val) {
+window.removeFromArray = function (arr, val) {
 	for (let i = 0; i < arr.length; i++) {
 		if (val === arr[i]) {
 			return arr.splice(i, 1);
@@ -64,11 +64,12 @@ window.removeFromArray = function(arr, val) {
  * @param {any[]} arr
  * @param {any} callback
  * @param {any} thisArg
+ * @returns {Array}
  */
-window.filterInPlace = function(arr, callback, thisArg) {
+window.filterInPlace = function (arr, callback, thisArg) {
 	let j = 0;
 
-	arr.forEach(function(e, i) {
+	arr.forEach(function (e, i) {
 		if (callback.call(thisArg, e, i, arr)) {
 			arr[j++] = e;
 		}
@@ -83,7 +84,7 @@ window.filterInPlace = function(arr, callback, thisArg) {
  * @param {App.Entity.SlaveState} slave2
  * @returns {boolean}
  */
-window.canBreed = function(slave1, slave2) {
+window.canBreed = function (slave1, slave2) {
 	if (!slave1 || !slave2) {
 		return null;
 	}
@@ -97,7 +98,7 @@ window.canBreed = function(slave1, slave2) {
  * @param {App.Entity.SlaveState} slave2
  * @returns {boolean}
  */
-window.canImpreg = function(slave1, slave2) {
+window.canImpreg = function (slave1, slave2) {
 	if (!slave1 || !slave2) {
 		return null;
 	} else if (slave2.dick < 1) {
@@ -140,10 +141,10 @@ window.canImpreg = function(slave1, slave2) {
 
 /**
  * Determines whether PC is fertile
- * @param {{ preg: number; pregWeek: number; vagina: number; }} PC
+ * @param {object} PC
  * @returns {boolean}
  */
-window.isPlayerFertile = function(PC) {
+window.isPlayerFertile = function (PC) {
 	if (!PC) {
 		return null;
 	} else if (PC.preg !== 0) {
@@ -163,7 +164,7 @@ window.isPlayerFertile = function(PC) {
  * @param {App.Entity.SlaveState} slave
  * @returns {string|number}
  */
-window.relationTargetWord = function(slave) {
+window.relationTargetWord = function (slave) {
 	if (!slave) {
 		return null;
 	} else if (slave.relation === "daughter") {
@@ -178,7 +179,7 @@ window.relationTargetWord = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {number}
  */
-window.milkAmount = function(slave) {
+window.milkAmount = function (slave) {
 	let milk;
 	let calcs;
 	if (!slave) {
@@ -228,7 +229,7 @@ window.milkAmount = function(slave) {
  * @param {App.Entity.SlaveState} slave
  * @returns {number}
  */
-window.cumAmount = function(slave) {
+window.cumAmount = function (slave) {
 	let cum = 0;
 	let calcs = 0;
 	if (!slave) {
@@ -278,7 +279,7 @@ window.cumAmount = function(slave) {
  * @param {string} text
  * @returns {string}
  */
-window.lispReplace = function(text) {
+window.lispReplace = function (text) {
 	text = text.replace(/Sh/g, "Th");
 	text = text.replace(/SS/g, "Th");
 	text = text.replace(/Ss/g, "Th");
@@ -366,7 +367,7 @@ window.lispReplace = function(text) {
  * @param {Object} arcology
  * @returns {number}
  */
-window.repGainSacrifice = function(slave, arcology) {
+window.repGainSacrifice = function (slave, arcology) {
 	if (!slave || !arcology || arcology.FSAztecRevivalist === "unset" || arcology.FSAztecRevivalist <= 0) {
 		return 0;
 	}
@@ -378,33 +379,33 @@ window.repGainSacrifice = function(slave, arcology) {
  * @param {App.Entity.SlaveState} slave
  * @returns {boolean}
  */
-window.bodyguardSuccessorEligible = function(slave) {
+window.bodyguardSuccessorEligible = function (slave) {
 	if (!slave) {
 		return false;
 	}
 	return (slave.devotion > 50 && slave.muscles >= 0 && slave.weight < 100 && slave.boobs < 8000 && slave.butt < 10 && slave.belly < 5000 && slave.balls < 10 && slave.dick < 10 && slave.preg < 20 && slave.fuckdoll === 0 && slave.fetish !== "mindbroken" && canWalk(slave));
 };
 
-window.ngUpdateGenePool = function(genePool) {
+window.ngUpdateGenePool = function (genePool) {
 	const transferredSlaveIds = (State.variables.slaves || [])
-		.filter(function(s) {
+		.filter(function (s) {
 			return s.ID >= 1200000;
 		})
-		.map(function(s) {
+		.map(function (s) {
 			return s.ID - 1200000;
 		});
 	return (genePool || [])
-		.filter(function(s) {
+		.filter(function (s) {
 			return transferredSlaveIds.indexOf(s.ID) >= 0;
 		})
-		.map(function(s) {
+		.map(function (s) {
 			const result = jQuery.extend(true, {}, s);
 			result.ID += 1200000;
 			return result;
 		});
 };
 
-window.ngUpdateMissingTable = function(missingTable) {
+window.ngUpdateMissingTable = function (missingTable) {
 	const newTable = {};
 
 	(State.variables.slaves || [])
@@ -422,7 +423,7 @@ window.ngUpdateMissingTable = function(missingTable) {
  * @param {any} obj
  * @returns {string}
  */
-window.toJson = function(obj) {
+window.toJson = function (obj) {
 	let jsontext = JSON.stringify(obj);
 	jsontext = jsontext.replace(/^{/, "");
 	jsontext = jsontext.replace(/}$/, "");
@@ -466,7 +467,7 @@ window.nippleColor = function (slave) {
  * @param {Object} PC
  * @returns {number}
  */
-window.overpowerCheck = function(slave, PC) {
+window.overpowerCheck = function (slave, PC) {
 	let strength;
 
 	if (State.variables.arcologies[0].FSPhysicalIdealist !== "unset") {
@@ -493,7 +494,7 @@ window.overpowerCheck = function(slave, PC) {
 * @param {App.Entity.SlaveState} slave
 * @returns {number[]}
 */
-window.impregnatedBy = function(slave) {
+window.impregnatedBy = function (slave) {
 	const IDArray = [];
 	if (!Array.isArray(slave.womb)) {
 		WombInit(slave);
@@ -510,15 +511,15 @@ window.impregnatedBy = function(slave) {
  * @param {App.Entity.SlaveState} father
  * @returns {boolean}
  */
-window.isImpregnatedBy = function(mother, father) {
+window.isImpregnatedBy = function (mother, father) {
 	return impregnatedBy(mother).includes(father.ID);
 };
 
-window.jsAlert = function(obj) {
+window.jsAlert = function (obj) {
 	alert(obj);
 };
 
-window.jsConsoleInfo = function(obj) {
+window.jsConsoleInfo = function (obj) {
 	// eslint-disable-next-line no-console
 	console.info(obj);
 };
@@ -596,9 +597,9 @@ window.SoftenSexualFlaw = function SoftenSexualFlaw(slave) {
 };
 
 /**
- * @param {{ title: number; pronoun: string; possessivePronoun: string; possessive: string; object: string; objectReflexive: string; noun: string; }} PC
+ * @param {object} PC
  */
-window.generatePlayerPronouns = function(PC) {
+window.generatePlayerPronouns = function (PC) {
 	if (PC.title === 0) {
 		PC.pronoun = "she";
 		PC.possessivePronoun = "hers";
@@ -616,7 +617,7 @@ window.generatePlayerPronouns = function(PC) {
 	}
 };
 
-window.generateAssistantPronouns = function() {
+window.generateAssistantPronouns = function () {
 	const V = State.variables;
 	if (V.assistant === 0) {
 		V.assistantPronouns.pronoun = "it";
diff --git a/src/js/textInput.js b/src/js/textInput.js
index ba89308e4e948ac2988088f88b358830d6795b08..00bffdaac33247f9d888216acb26b32665d70f75 100644
--- a/src/js/textInput.js
+++ b/src/js/textInput.js
@@ -2,11 +2,15 @@ Macro.add("textinput", {
 	// Signifies that the macro is a container macro.
 	tags: null,
 
-	handler: function() {
+	handler: function () {
 		if (this.args.length < 2) {
 			const errors = [];
-			if (this.args.length < 1) { errors.push("variable name"); }
-			if (this.args.length < 2) { errors.push("default value"); }
+			if (this.args.length < 1) {
+				errors.push("variable name");
+			}
+			if (this.args.length < 2) {
+				errors.push("default value");
+			}
 			return this.error(`no ${errors.join(" or ")} specified`);
 		}
 
@@ -34,7 +38,7 @@ Macro.add("textinput", {
 				tabindex: 0 // for accessibility
 			})
 			.addClass("macro-textarea") // "hijack" the .macro-textarea class
-			.on("input", function() {
+			.on("input", function () {
 				Wikifier.setValue(varName, this.value);
 				if (that.payload[0].contents !== "") {
 					Wikifier.wikifyEval(that.payload[0].contents.trim());