 		NSLog("iosrtcPlugin#MediaStreamTrack_stop()")
 
 		let id = command.argumentAtIndex(0) as! String
-		let pluginMediaStreamTrack = self.pluginMediaStreamTracks[id]
+		weak var pluginMediaStreamTrack = self.pluginMediaStreamTracks[id]
 
 		if pluginMediaStreamTrack == nil {
 			NSLog("iosrtcPlugin#MediaStreamTrack_stop() | ERROR: pluginMediaStreamTrack with id=\(id) does not exist")

			options = command.argumentAtIndex(3) as? NSDictionary
		}

		let pluginRTCPeerConnection = self.pluginRTCPeerConnections[pcId]

		if pluginRTCPeerConnection == nil {
			NSLog("iosrtcPlugin#RTCPeerConnection_createDataChannel() | ERROR: pluginRTCPeerConnection with pcId=\(pcId) does not exist")


		let pcId = command.argumentAtIndex(0) as! Int
		let streamId = command.argumentAtIndex(1) as! String
		weak var pluginRTCPeerConnection = self.pluginRTCPeerConnections[pcId]
		weak var pluginMediaStream = self.pluginMediaStreams[streamId]

		if pluginRTCPeerConnection == nil {
			NSLog("iosrtcPlugin#RTCPeerConnection_addStream() | ERROR: pluginRTCPeerConnection with pcId=\(pcId) does not exist")
