diff --git a/htdocs/lib/Measurement.js b/htdocs/lib/Measurement.js index 018739c..202070e 100644 --- a/htdocs/lib/Measurement.js +++ b/htdocs/lib/Measurement.js @@ -1,6 +1,6 @@ function Measurement() { this.reset(); -}; +} Measurement.prototype.add = function(v) { this.value += v; @@ -25,7 +25,7 @@ Measurement.prototype.reset = function() { Measurement.prototype.report = function(range, interval, callback) { return new Reporter(this, range, interval, callback); -} +}; function Reporter(measurement, range, interval, callback) { this.measurement = measurement; @@ -33,7 +33,7 @@ function Reporter(measurement, range, interval, callback) { this.samples = []; this.callback = callback; this.interval = setInterval(this.report.bind(this), interval); -}; +} Reporter.prototype.sample = function(){ this.samples.push({ diff --git a/htdocs/openwebrx.js b/htdocs/openwebrx.js index 33bb590..1a88e2d 100644 --- a/htdocs/openwebrx.js +++ b/htdocs/openwebrx.js @@ -1973,7 +1973,7 @@ function update_dmr_timeslot_filtering() { function playButtonClick() { //On iOS, we can only start audio from a click or touch event. audioEngine.start(onAudioStart); - $overlay = $('#openwebrx-autoplay-overlay'); + var $overlay = $('#openwebrx-autoplay-overlay'); $overlay.css('opacity', 0); $overlay.on('transitionend', function() { $overlay.hide(); @@ -2051,7 +2051,7 @@ function initPanels() { el.style.transitionDuration = null; el.style.transitionDelay = null; el.style.transitionProperty = null; - if (el.movement && el.movement == 'collapse') { + if (el.movement && el.movement === 'collapse') { el.style.display = 'none'; } }); @@ -2221,16 +2221,14 @@ function secondary_demod_push_data(x) { var c = y.charCodeAt(0); return (c === 10 || (c >= 32 && c <= 126)); }).map(function (y) { - if (y === "&" - ) + if (y === "&") return "&"; if (y === "<") return "<"; if (y === ">") return ">"; if (y === " ") return " "; return y; }).map(function (y) { - if (y === "\n" - ) + if (y === "\n") return "
"; return "" + y + ""; }).join("");