From 5add85bd60f6e4c82996666d21560dca5d4e5e60 Mon Sep 17 00:00:00 2001 From: Eric Rosenbaum Date: Fri, 23 Jun 2017 11:58:04 -0400 Subject: [PATCH] Fix comments --- src/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.js b/src/index.js index 3cc959d..c5fc058 100644 --- a/src/index.js +++ b/src/index.js @@ -292,7 +292,7 @@ class AudioEngine { * @return {number} loudness scaled 0 to 100 */ getLoudness () { - // the microphone has not been set up, try to connect to it + // The microphone has not been set up, so try to connect to it if (!this.mic && !this.connectingToMic) { this.connectingToMic = true; // prevent multiple connection attempts navigator.mediaDevices.getUserMedia({audio: true}).then(stream => { @@ -306,7 +306,7 @@ class AudioEngine { }); } - // if the microphone is set up and active, measure the loudness + // If the microphone is set up and active, measure the loudness if (this.mic && this.mic.mediaStream.active) { this.analyser.getFloatTimeDomainData(this.micDataArray); let sum = 0;