From dd8529bd88f63fa1b2c05c8304637ffb3b2bef1b Mon Sep 17 00:00:00 2001 From: Hexagon Date: Wed, 30 Dec 2015 00:42:00 +0100 Subject: [PATCH] Oops --- public/js/cryptalk_modules/audio.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/js/cryptalk_modules/audio.js b/public/js/cryptalk_modules/audio.js index 365c3b0..99e1132 100644 --- a/public/js/cryptalk_modules/audio.js +++ b/public/js/cryptalk_modules/audio.js @@ -41,8 +41,8 @@ define(['queue','castrato','templates'], function (queue,mediator,templates) { o.connect(g); g.gain.value = 0.25; g.connect(ac.destination); - queue.add_function_delayed(start,function() { o.noteOn && o.noteOn(0) || o.start(0); }); - queue.add_function_delayed(start+duration,function() { o.noteOff && o.noteOff(0) || o.stop(0); }); + queue.add_function_delayed(start,function() { o.noteOn ? o.noteOn(0) : o.start(0); }); + queue.add_function_delayed(start+duration,function() { o.noteOff ? o.noteOff(0) : o.stop(0); }); // Iterate, or start playing i++;