Added socket.io

This commit is contained in:
2024-07-31 19:01:55 -04:00
parent fc66225cf5
commit 441e372987
23 changed files with 551 additions and 151 deletions
+5 -5
View File
@@ -1,7 +1,7 @@
'use strict';
const Table = require('../utils/redis_model');
const {Token, InviteToken} = require('./token');
// const {Token, InviteToken} = require('./token');
const bcrypt = require('bcrypt');
const saltRounds = 10;
@@ -32,7 +32,7 @@ class User extends Table{
}
}
static async addByInvite(data){
/* static async addByInvite(data){
try{
let token = await InviteToken.get(data.token);
@@ -55,7 +55,7 @@ class User extends Table{
throw error;
}
};
};*/
async setPassword(data){
try{
@@ -67,7 +67,7 @@ class User extends Table{
}
}
async invite(){
/* async invite(){
try{
let token = await InviteToken.add({created_by: this.username});
@@ -76,7 +76,7 @@ class User extends Table{
}catch(error){
throw error;
}
}
}*/
static async login(data){
try{