mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-12-08 20:48:48 +00:00
More typechecking
This commit is contained in:
@@ -1,6 +1,11 @@
|
||||
function password(inp, coll, guid, offline, socket) {
|
||||
if(inp !== undefined && inp !== null && inp !== "")
|
||||
{
|
||||
if(!inp.hasOwnProperty("password") || !inp.hasOwnProperty("channel") ||
|
||||
typeof(inp.password) != "string" || typeof(inp.channel) != "string") {
|
||||
socket.emit("update_required");
|
||||
return;
|
||||
}
|
||||
pw = inp.password;
|
||||
opw = inp.password;
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user