mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-07-09 17:04:58 +02:00
Adding and deleting users
This commit is contained in:
parent
88c7c1632e
commit
23f343f1df
15 changed files with 323 additions and 12 deletions
|
@ -58,6 +58,7 @@ class Db {
|
|||
pash: '',
|
||||
stream: null,
|
||||
token,
|
||||
isActive: true,
|
||||
createdAt: Date.now()
|
||||
})
|
||||
}
|
||||
|
@ -115,8 +116,10 @@ class Db {
|
|||
return this.usersDb.insert([user]).then((results) => {
|
||||
Logger.debug(`[DB] Inserted user ${results.inserted}`)
|
||||
this.users.push(user)
|
||||
return true
|
||||
}).catch((error) => {
|
||||
Logger.error(`[DB] Insert user Failed ${error}`)
|
||||
return false
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue