Browse Source

Removed uneccessary global variable in example chat

Josh Hamit 11 năm trước cách đây
mục cha
commit
c69c755666
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      examples/chat.html

+ 1 - 1
examples/chat.html

@@ -106,7 +106,7 @@ $(document).ready(function() {
 
   // Connect to a peer
   $('#connect').click(function() {
-    requestedPeer = $('#rid').val();
+    var requestedPeer = $('#rid').val();
     if (!connectedPeers[requestedPeer]) {
       // Create 2 connections, one labelled chat and another labelled file.
       var c = peer.connect(requestedPeer, {