diff --git a/html5/verto/js/src/jquery.FSRTC.js b/html5/verto/js/src/jquery.FSRTC.js
index ed8a5500d8..f07188bedb 100644
--- a/html5/verto/js/src/jquery.FSRTC.js
+++ b/html5/verto/js/src/jquery.FSRTC.js
@@ -341,6 +341,9 @@
$.FSRTC.prototype.setMute = function(what) {
var self = this;
+ if (!self.localStream) {
+ return false;
+ }
var audioTracks = self.localStream.getAudioTracks();
for (var i = 0, len = audioTracks.length; i < len; i++ ) {
@@ -370,6 +373,9 @@
$.FSRTC.prototype.setVideoMute = function(what) {
var self = this;
+ if (!self.localStream) {
+ return false;
+ }
var videoTracks = self.localStream.getVideoTracks();
for (var i = 0, len = videoTracks.length; i < len; i++ ) {