mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-12-08 20:48:48 +00:00
more ensurance id is string
This commit is contained in:
@@ -507,7 +507,7 @@ function add_function(arr, coll, guid, offline, socket) {
|
||||
function voteUndecided(msg, coll, guid, offline, socket) {
|
||||
var socketid = socket.zoff_id;
|
||||
if(typeof(msg) === 'object' && msg !== undefined && msg !== null){
|
||||
|
||||
if(msg.hasOwnProperty("id")) msg.id = msg.id + "";
|
||||
if(!msg.hasOwnProperty("channel") || !msg.hasOwnProperty("id") ||
|
||||
!msg.hasOwnProperty("type") || typeof(msg.channel) != "string" ||
|
||||
typeof(msg.id) != "string" || typeof(msg.type) != "string") {
|
||||
|
||||
Reference in New Issue
Block a user