Remove user.leave()

This commit is contained in:
emad-salah 2021-11-04 13:32:40 +01:00
parent 53a8d44f69
commit 9e3b78546a

View file

@ -392,15 +392,11 @@ const authenticate = async (alias, pass, __user) => {
} }
} }
const logoff = () => {
user.leave()
}
const instantiateGun = () => { const instantiateGun = () => {
const Config = require('../config') const Config = require('../config')
if (user) { // if (user) {
user.leave() // user.leave()
} // }
// @ts-ignore // @ts-ignore
user = null user = null
if (gun) { if (gun) {
@ -523,7 +519,7 @@ const register = async (alias, pass) => {
module.exports = { module.exports = {
authenticate, authenticate,
logoff, instantiateGun,
isAuthenticated, isAuthenticated,
isAuthenticating, isAuthenticating,
isRegistering, isRegistering,