From 0ffbb6bbd689fc03179520898c124cbfb966337d Mon Sep 17 00:00:00 2001 From: Daniel Lugo Date: Thu, 29 Apr 2021 15:54:35 -0400 Subject: [PATCH] Remove unnecessary gun subs (let front handle) --- services/gunDB/contact-api/events/onSentReqs.js | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/services/gunDB/contact-api/events/onSentReqs.js b/services/gunDB/contact-api/events/onSentReqs.js index 653ad3dc..f06518e1 100644 --- a/services/gunDB/contact-api/events/onSentReqs.js +++ b/services/gunDB/contact-api/events/onSentReqs.js @@ -51,10 +51,6 @@ const react = debounce(() => { // maps a pk to a feed, messages if subbed and pk is pubbing, null / // 'disconnected' otherwise const pubToFeed = Streams.getPubToFeed() - // pk to avatar - const pubToAvatar = Streams.getPubToAvatar() - // pk to display name - const pubToDN = Streams.getPubToDn() logger.info(`pubToLastSentREqID length: ${size(pubToLastSentReqID)}`) @@ -80,18 +76,6 @@ const react = debounce(() => { // eslint-disable-next-line no-empty-function Streams.onAddresses(() => {}, recipientPub)() } - // no avatar for this pk? let's ask the corresponding stream to sub to - // gun.user(pk).get('avatar') - if (typeof pubToAvatar[recipientPub] === 'undefined') { - // eslint-disable-next-line no-empty-function - Streams.onAvatar(() => {}, recipientPub)() - } - // no display name for this pk? let's ask the corresponding stream to sub to - // gun.user(pk).get('displayName') - if (typeof pubToDN[recipientPub] === 'undefined') { - // eslint-disable-next-line no-empty-function - Streams.onDisplayName(() => {}, recipientPub)() - } newReqs.push({ id: sentReqID,