index.js
function() {
      if(!volume) {
        return;
      } else if (volume.muted) {
        p.unmute(function(err, status) {
          if (err) return;
          volume = status;
        });
      } else {
        p.mute(function(err, status) {
          if (err) return;
          volume = status;
        });
      }
    }
function() {
      if(!volume) {
        return;
      } else if (volume.muted) {
        p.unmute(function(err, status) {
          if (err) return;
          volume = status;
        });
      } else {
        p.mute(function(err, status) {
          if (err) return;
          volume = status;
        });
      }
    }
function ( ) { if ( ! volume ) { return ; } else if ( volume . muted ) { p . unmute ( function ( err , status ) { if ( err ) return ; volume = status ; } ) ; } else { p . mute ( function ( err , status ) { if ( err ) return ; volume = status ; } ) ; } }
toggle between mute / unmute
toggle between mute / unmute