title: Stop if already playing
body: <p>I need some assistance implementing the .playing() method, for when my playSound function is called i want to stop anything that is currently playing, and play the newly requested sound, here is my example which is not stopping each time its called:</p>
  
  <pre><code>  function playSound(audio) {
        var playing;
        var sound = new Howl({
          src: ['assets/sound/voice/' + audio],
          autoplay: false,
          volume: 0.9,
          onplay: function() {
            playing = true;
          },
          onend: function() {
            playing = false;
          }          
        });
  
        if(playing) {
          sound.stop();
        } else {            
          sound.play();      
        }
    }
  </code></pre>