From 1b5f3def09fa4fdd57968cb551fadd539b0934f5 Mon Sep 17 00:00:00 2001
From: lowercasedonkey <lowercasedonkey@gmail.com>
Date: Tue, 10 Nov 2020 02:09:25 -0500
Subject: [PATCH] cleanup again

---
 src/endWeek/reports/penthouseReport.js | 16 ++++++----------
 1 file changed, 6 insertions(+), 10 deletions(-)

diff --git a/src/endWeek/reports/penthouseReport.js b/src/endWeek/reports/penthouseReport.js
index 84d7079dcd7..1938402d49a 100644
--- a/src/endWeek/reports/penthouseReport.js
+++ b/src/endWeek/reports/penthouseReport.js
@@ -161,9 +161,9 @@ App.EndWeek.penthouseReport = function() {
 		}
 
 		if (V.HGTrainSlavesIDs.length > 0) {
-			const girlsGirl = V.HGTrainSlavesIDs.find(trainee => slave.ID === trainee.ID);
-			if (girlsGirl) {
-				r.push(HGApplication(girlsGirl));
+			const trainee = V.HGTrainSlavesIDs.find(trainee => slave.ID === trainee.ID);
+			if (trainee) {
+				r.push(HGApplication(slave, trainee.training));
 			}
 		}
 
@@ -173,15 +173,11 @@ App.EndWeek.penthouseReport = function() {
 	}
 
 	/**
-	 * @param {object} girlsGirl
-	 * @param {number} girlsGirl.ID
-	 * @param {string} girlsGirl.training
+	 * @param {App.Entity.SlaveState} slave
+	 * @param {string} headGirlsTraining
 	 */
-	function HGApplication(girlsGirl) {
+	function HGApplication(slave, headGirlsTraining) {
 		const el = document.createElement("span");
-		const slave = getSlave(girlsGirl.ID);
-		const headGirlsTraining = girlsGirl.training;
-
 		const {
 			He, His,
 			he, his, him, himself, girl
-- 
GitLab