Remove unnecessary gun subs (let front handle)
This commit is contained in:
parent
0ffbb6bbd6
commit
2be84451d1
1 changed files with 0 additions and 13 deletions
|
|
@ -44,22 +44,11 @@ const react = debounce(() => {
|
|||
const newReceivedReqsMap = {}
|
||||
|
||||
const pubToFeed = Streams.getPubToFeed()
|
||||
const pubToAvatar = Streams.getPubToAvatar()
|
||||
const pubToDn = Streams.getPubToDn()
|
||||
|
||||
for (const [id, req] of Object.entries(currAddressData)) {
|
||||
const inContact = Array.isArray(pubToFeed[req.from])
|
||||
const isDisconnected = pubToFeed[req.from] === 'disconnected'
|
||||
|
||||
if (typeof pubToAvatar[req.from] === 'undefined') {
|
||||
// eslint-disable-next-line no-empty-function
|
||||
Streams.onAvatar(() => {}, req.from)()
|
||||
}
|
||||
if (typeof pubToDn[req.from] === 'undefined') {
|
||||
// eslint-disable-next-line no-empty-function
|
||||
Streams.onDisplayName(() => {}, req.from)()
|
||||
}
|
||||
|
||||
if (!inContact && !isDisconnected) {
|
||||
newReceivedReqsMap[req.from] = {
|
||||
id,
|
||||
|
|
@ -133,8 +122,6 @@ const onReceivedReqs = cb => {
|
|||
}
|
||||
}, user)
|
||||
|
||||
Streams.onAvatar(react)
|
||||
Streams.onDisplayName(react)
|
||||
Streams.onPubToFeed(react)
|
||||
|
||||
subbed = true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue