From 831e5d97b93768b80902c7a6e66a8538e89f9c78 Mon Sep 17 00:00:00 2001 From: Michael Ziegler Date: Fri, 23 Jul 2010 09:35:02 +0200 Subject: [PATCH] add "var" keywords before some variables --- htdocs/js/channelviewer.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/htdocs/js/channelviewer.js b/htdocs/js/channelviewer.js index d3e3f2e..9751b96 100644 --- a/htdocs/js/channelviewer.js +++ b/htdocs/js/channelviewer.js @@ -29,8 +29,8 @@ Ext.extend( Ext.ux.MumbleChannelViewer, Ext.tree.TreePanel, { url: this.source_url, scope: this, success: function( resp, opt ){ - respdata = Ext.decode( resp.responseText ); - root = { + var respdata = Ext.decode( resp.responseText ); + var root = { text: respdata.name, id: "mumbroot", leaf: false, @@ -38,9 +38,9 @@ Ext.extend( Ext.ux.MumbleChannelViewer, Ext.tree.TreePanel, { children: [], }; function populateNode( node, json ){ - subchan_users = 0; + var subchan_users = 0; for( var i = 0; i < json.channels.length; i++ ){ - child = { + var child = { text: json.channels[i].name, id: ("channel_" + json.channels[i].id), leaf: false, @@ -51,7 +51,7 @@ Ext.extend( Ext.ux.MumbleChannelViewer, Ext.tree.TreePanel, { subchan_users += populateNode( child, json.channels[i] ); } for( var i = 0; i < json.users.length; i++ ){ - child = { + var child = { text: json.users[i].name, id: ("user_" + json.users[i].id), leaf: true,