From a2b58f92d44a12f8047ecc2fbb224905cf719f63 Mon Sep 17 00:00:00 2001
From: Skriv <skrivelese@gmail.com>
Date: Wed, 10 Apr 2019 21:39:10 +0200
Subject: [PATCH] un-nest ternary

---
 src/js/utilJS.js | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/js/utilJS.js b/src/js/utilJS.js
index 5da048fc6d9..c06363b153a 100644
--- a/src/js/utilJS.js
+++ b/src/js/utilJS.js
@@ -935,7 +935,12 @@ window.dickToInchString = function(s) {
 
 // takes a dick value e.g. $activeSlave.dick, returns an int of the dick length in cm
 window.dickToCM = function(s) {
-	return (s<9?s*5:(s===9?50:s*6));
+	if (s < 9) {
+		return s*5;
+	} else if (s === 9) {
+		return 50;
+	}
+	return s*6;
 };
 
 // takes a ball value e.g. $activeSlave.balls, returns a string in the format 3 inches
-- 
GitLab