mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-12-08 20:48:48 +00:00
Added timeout for skips for 1 second
This commit is contained in:
@@ -182,7 +182,6 @@ function skip(list, guid, coll, offline, socket) {
|
||||
|
||||
db.collection(coll + "_settings").find(function(err, docs){
|
||||
if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (list.hasOwnProperty('userpass') && docs[0].userpass == list.userpass))) {
|
||||
|
||||
Functions.check_inlist(coll, guid, socket, offline, undefined, "place 12");
|
||||
|
||||
adminpass = "";
|
||||
@@ -198,7 +197,8 @@ function skip(list, guid, coll, offline, socket) {
|
||||
}
|
||||
|
||||
hash = adminpass;
|
||||
|
||||
var toCompare = list.error
|
||||
Functions.checkTimeout("skip", 1, coll, coll, error, true, socket, function() {
|
||||
//db.collection(coll + "_settings").find(function(err, docs){
|
||||
|
||||
if(docs !== null && docs.length !== 0)
|
||||
@@ -239,6 +239,7 @@ function skip(list, guid, coll, offline, socket) {
|
||||
}else
|
||||
socket.emit("toast", "noskip");
|
||||
}
|
||||
});
|
||||
//});
|
||||
} else {
|
||||
socket.emit("auth_required");
|
||||
|
||||
Reference in New Issue
Block a user