                                         @listenForMessage connection
 
                 connection.on "close", =>
+                    if @selfUnmount
+                        return
+
                     @props.addAlert type: "warning", "Founder left the channel!"
 
-                peer.on "connection", (connection) =>
+                @peer.on "connection", (connection) =>
                     connection.on "open", =>
                         @connections.push connection
                         @listenForMessage connection
 
                         @showAlertAboutNewConnection()
+
+    componentWillUnmount: ->
+        @selfUnmount = true
+
+        @peer.destroy()
 
     render: ->
         (Dom.div null,

                    connection.on "data", (data) =>
                        if data.type == "newConnection"
                            _.forEach data.peerIds, (peerId) =>
                                connection = peer.connect peerId

                                do (connection) =>
                                    connection.on "open", =>

            if not isFounder
                @setState peerIdForFounder: peerIdForFounder

                connection = @peer.connect peerIdForFounder

                connection.on "open", =>
                    @connections.push connection
