From 7a8e828cd56768eb11e48e1dcf12eebb648dde69 Mon Sep 17 00:00:00 2001 From: Miguel Jacq Date: Wed, 14 Feb 2018 17:04:08 +1100 Subject: [PATCH] Fix indentation --- share/html/index.html | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/share/html/index.html b/share/html/index.html index d5d36055..f3fe8247 100644 --- a/share/html/index.html +++ b/share/html/index.html @@ -182,27 +182,27 @@ if (unhumanize(x.innerHTML.toLowerCase()) < unhumanize(y.innerHTML.toLowerCase())) { // If so, mark as a switch and break the loop: shouldSwitch= true; - break; + break; + } + } + } + if (shouldSwitch) { + /* If a switch has been marked, make the switch + and mark that a switch has been done: */ + rows[i].parentNode.insertBefore(rows[i + 1], rows[i]); + switching = true; + // Each time a switch is done, increase this count by 1: + switchcount ++; + } else { + /* If no switching has been done AND the direction is "asc", + set the direction to "desc" and run the while loop again. */ + if (switchcount == 0 && dir == "asc") { + dir = "desc"; + switching = true; } } } - if (shouldSwitch) { - /* If a switch has been marked, make the switch - and mark that a switch has been done: */ - rows[i].parentNode.insertBefore(rows[i + 1], rows[i]); - switching = true; - // Each time a switch is done, increase this count by 1: - switchcount ++; - } else { - /* If no switching has been done AND the direction is "asc", - set the direction to "desc" and run the while loop again. */ - if (switchcount == 0 && dir == "asc") { - dir = "desc"; - switching = true; - } - } } - } - +