correct typo

edit
Albert 2019-02-11 09:05:46 +00:00
parent 90473eeb05
commit 9e3a52f14a
1 changed files with 1 additions and 1 deletions

View File

@ -45,7 +45,7 @@ app.get("/", function(req, res) {
app.get("/token", function(req,res) { app.get("/token", function(req,res) {
var ts = new Date().getTime(); var ts = new Date().getTime();
var rand = new Uint32Array(1); var rand = new Uint32Array(1);
window.crypto.getRandomValues(array) window.crypto.getRandomValues(rand)
var secret = ts.toString() + rand.toString(); var secret = ts.toString() + rand.toString();
res.send({secret: secret, socketId: createHash(secret)}); res.send({secret: secret, socketId: createHash(secret)});
}); });