JavaScript conditionals require parens as part of the grammar
authorM. Taylor Saotome-Westlake <ultimatelyuntruethought@gmail.com>
Sun, 18 Sep 2022 01:06:30 +0000 (18:06 -0700)
committerM. Taylor Saotome-Westlake <ultimatelyuntruethought@gmail.com>
Sun, 18 Sep 2022 01:06:30 +0000 (18:06 -0700)
Maybe correctly remembering JavaScript syntax will help me feel less
gross.

theme/static/js/comment_counts.js

index ced469a..3bb5866 100644 (file)
@@ -18,7 +18,7 @@ function placeCommentCounts() {
             for (let [i, container] of containers.entries()) {
                 let a = document.createElement('a');
                 let count = counts[i];
-                if count === 0 {
+                if (count === 0) {
                     count = "no";
                 }
                 let pluralizer = count === 1 ? "" : "s";