parallel
This commit is contained in:
parent
b72604075f
commit
2eac1eaaf7
1 changed files with 51 additions and 49 deletions
|
|
@ -1061,7 +1061,8 @@ const disconnect = async pub => {
|
|||
pub
|
||||
))
|
||||
|
||||
await new Promise((res, rej) => {
|
||||
await Promise.all([
|
||||
new Promise((res, rej) => {
|
||||
user
|
||||
.get(Key.USER_TO_INCOMING)
|
||||
.get(pub)
|
||||
|
|
@ -1072,9 +1073,9 @@ const disconnect = async pub => {
|
|||
res()
|
||||
}
|
||||
})
|
||||
})
|
||||
}),
|
||||
|
||||
await new Promise((res, rej) => {
|
||||
new Promise((res, rej) => {
|
||||
user
|
||||
.get(Key.RECIPIENT_TO_OUTGOING)
|
||||
.get(pub)
|
||||
|
|
@ -1085,9 +1086,9 @@ const disconnect = async pub => {
|
|||
res()
|
||||
}
|
||||
})
|
||||
})
|
||||
}),
|
||||
|
||||
await new Promise((res, rej) => {
|
||||
new Promise((res, rej) => {
|
||||
user
|
||||
.get(Key.USER_TO_LAST_REQUEST_SENT)
|
||||
.get(pub)
|
||||
|
|
@ -1098,9 +1099,9 @@ const disconnect = async pub => {
|
|||
res()
|
||||
}
|
||||
})
|
||||
})
|
||||
}),
|
||||
|
||||
await new Promise((res, rej) => {
|
||||
new Promise((res, rej) => {
|
||||
user
|
||||
.get(Key.OUTGOINGS)
|
||||
.get(outGoingID)
|
||||
|
|
@ -1111,9 +1112,10 @@ const disconnect = async pub => {
|
|||
res()
|
||||
}
|
||||
})
|
||||
})
|
||||
}),
|
||||
|
||||
await generateHandshakeAddress(require('../Mediator').getUser())
|
||||
])
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue