mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-10-29 18:00:23 +00:00
Fixed critical crash issue with shuffling
This commit is contained in:
2
server/public/assets/dist/embed.min.js
vendored
2
server/public/assets/dist/embed.min.js
vendored
File diff suppressed because one or more lines are too long
2
server/public/assets/dist/main.min.js
vendored
2
server/public/assets/dist/main.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -478,7 +478,7 @@ var List = {
|
||||
|
||||
skip: function(){
|
||||
if(!offline){
|
||||
socket.emit('skip', {pass: adminpass, id:video_id, channel: chan.toLowerCase(), pass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
socket.emit('skip', {pass: adminpass, id:video_id, channel: chan.toLowerCase(), userpass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
} else {
|
||||
Player.playNext();
|
||||
}
|
||||
|
||||
@@ -481,7 +481,7 @@ function chromecastListener(evt, data){
|
||||
if(offline){
|
||||
Player.playNext();
|
||||
} else {
|
||||
socket.emit("skip", {error: json_parsed.data_code, id: json_parsed.videoId, pass: adminpass, channel: chan.toLowerCase, pass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
socket.emit("skip", {error: json_parsed.data_code, id: json_parsed.videoId, pass: adminpass, channel: chan.toLowerCase, userpass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -320,7 +320,7 @@ var Player = {
|
||||
curr_playing = Player.player.getVideoUrl().replace("https://www.youtube.com/watch?v=", "");
|
||||
|
||||
|
||||
socket.emit("skip", {error: newState.data, id: video_id, pass: adminpass, channel: chan.toLowerCase, pass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
socket.emit("skip", {error: newState.data, id: video_id, pass: adminpass, channel: chan.toLowerCase, userpass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
//Helper.log(video_id, Player.player.getVideoUrl(), Player.player.getPlayerState());
|
||||
|
||||
/*}else{
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
<br>
|
||||
Do not redistribute without permission from the developers.
|
||||
<br>
|
||||
</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<a href="#" class="modal-action modal-close waves-effect waves-green btn-flat">Close</a>
|
||||
|
||||
@@ -746,7 +746,7 @@ io.on('connection', function(socket){
|
||||
}
|
||||
|
||||
db.collection(coll).find({views:{$exists:true}}, function(err, docs){
|
||||
if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (list.hasOwnProperty('pass') && docs[0].userpass == decrypt_string(socketid, list.pass)))) {
|
||||
if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (list.hasOwnProperty('userpass') && docs[0].userpass == decrypt_string(socketid, list.userpass)))) {
|
||||
|
||||
check_inlist(coll, guid, socket, name, offline);
|
||||
|
||||
@@ -921,8 +921,8 @@ io.on('connection', function(socket){
|
||||
|
||||
check_inlist(coll, guid, socket, name, offline);
|
||||
var hash;
|
||||
if(pass === "") hash = pass;
|
||||
else hash = hash_pass(decrypt_string(socketid, pass));
|
||||
if(msg.adminpass === "") hash = msg.adminpass;
|
||||
else hash = hash_pass(decrypt_string(socketid, msg.adminpass));
|
||||
db.collection(coll).find({views:{$exists:true}}, function(err, docs){
|
||||
if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (msg.hasOwnProperty('pass') && docs[0].userpass == decrypt_string(socketid, msg.pass)))) {
|
||||
if(docs !== null && docs.length !== 0 && ((docs[0].adminpass == hash || docs[0].adminpass === "") || docs[0].shuffle === false))
|
||||
|
||||
Reference in New Issue
Block a user