mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-10-29 18:00:23 +00:00
I should test things locally
This commit is contained in:
@@ -78,7 +78,7 @@ io.on('connection', function(socket){
|
||||
coll = list[0].toLowerCase();
|
||||
guid = list[1];
|
||||
|
||||
if(lists[coll] == undefined && !contains(lists[coll], guid))
|
||||
if(lists[coll] == undefined)
|
||||
{
|
||||
lists[coll] = [];
|
||||
lists[coll].push(guid);
|
||||
@@ -334,13 +334,10 @@ io.on('connection', function(socket){
|
||||
if(in_list)
|
||||
{
|
||||
try
|
||||
{
|
||||
if(contains(lists[coll], guid))
|
||||
{
|
||||
var index = lists[coll].indexOf(guid);
|
||||
lists[coll].splice(index, 1);
|
||||
io.sockets.emit(coll+",viewers", lists[coll].length);
|
||||
}
|
||||
}catch(err){}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user