aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/static
diff options
context:
space:
mode:
Diffstat (limited to 'juick-www/src/main/static')
-rw-r--r--juick-www/src/main/static/scripts.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/juick-www/src/main/static/scripts.js b/juick-www/src/main/static/scripts.js
index 3951bfae..7de14b34 100644
--- a/juick-www/src/main/static/scripts.js
+++ b/juick-www/src/main/static/scripts.js
@@ -19,9 +19,9 @@ var ws,
function initWS() {
var content = document.getElementById('content');
- if (!content) { return }
+ if (!content) { return; }
var pageMID = content.getAttribute('data-mid');
- if (!pageMID) { return }
+ if (!pageMID) { return; }
var url = (window.location.protocol === 'https:' ? 'wss' : 'ws') + ':'
+ (typeof juickDebug !== 'undefined' ?
@@ -158,7 +158,7 @@ function wsIncomingReply(msg) {
if (isTreeMode() && (msg.replyto > 0)) {
var p = document.getElementById(msg.replyto);
var m = parseInt(p.style.marginLeft) + 20;
- while (p.nextElementSibling && (parseInt(p.nextElementSibling.style.marginLeft) >= m)) p = p.nextElementSibling;
+ while (p.nextElementSibling && (parseInt(p.nextElementSibling.style.marginLeft) >= m)) { p = p.nextElementSibling; }
li.style.marginLeft = m + 'px';
p.parentNode.insertBefore(li, p.nextSibling);
} else {
@@ -231,7 +231,7 @@ function newMessage() {
function showMoreReplies(el, id) {
var foldedReplies = el.closest('li').querySelector('.msg-comments');
- if (!foldedReplies) { return }
+ if (!foldedReplies) { return; }
foldedReplies.style.display = 'none';
var replies = document.querySelectorAll('#replies>li'),
@@ -383,7 +383,7 @@ function unfoldReply() {
var anchor = window.location.hash.substring(1);
if ((0 + anchor) > 0) {
var el = document.getElementById(anchor);
- if (!el) { return }
+ if (!el) { return; }
while (el.style.display === 'none') {
el = el.previousElementSibling;
}
@@ -444,7 +444,7 @@ function closeDialog() {
function openSocialWindow(a) {
var w = window.open(a.href, 'juickshare', 'width=640,height=400');
- if (window.focus) w.focus();
+ if (window.focus) { w.focus(); }
return false;
}