only attempt announce with online peers

master
Kevin Froman 2018-07-03 14:26:53 -05:00
parent f1c8c8b843
commit 267220ad72
No known key found for this signature in database
GPG Key ID: 0D414D0FE405B63B
2 changed files with 2 additions and 2 deletions

View File

@ -313,7 +313,7 @@ class OnionrCommunicatorDaemon:
'''Announce to peers our address'''
announceCount = 0
announceAmount = 2
for peer in self._core.listAdders():
for peer in self.onlinePeers:
announceCount += 1
if self.peerAction(peer, 'announce', self._core.hsAdder) == 'Success':
logger.info('Successfully introduced node to ' + peer)

View File

@ -623,8 +623,8 @@ class Onionr:
'Onionr Daemon Status' : ((logger.colors.fg.green + 'Online') if self.onionrUtils.isCommunicatorRunning(timeout = 2) else logger.colors.fg.red + 'Offline'),
'Public Key' : self.onionrCore._crypto.pubKey,
'POW Token' : powToken,
'Human readable public key' : self.onionrCore._utils.getHumanReadableID(),
'Combined' : self.onionrCore._crypto.pubKey + '-' + powToken,
'Human readable public key' : self.onionrCore._utils.getHumanReadableID(),
'Node Address' : self.get_hostname(),
# file and folder size stats