use the new retryContact plugin

This commit is contained in:
Dan Ballard 2019-08-01 18:11:11 -07:00
parent 732d8ab671
commit 7e0786aea2
2 changed files with 3 additions and 5 deletions

View File

@ -1,6 +1,7 @@
package characters
import (
"cwtch.im/cwtch/app/plugins"
"cwtch.im/cwtch/event"
"cwtch.im/ui/go/cwutil"
"cwtch.im/ui/go/gobjects"
@ -66,6 +67,8 @@ func AppEventListener(gcd *gothings.GrandCentralDispatcher, subscribed chan bool
}
onion := e.Data[event.Identity]
the.CwtchApp.AddPeerPlugin(onion, plugins.CONTACTRETRY)
the.Peer = the.CwtchApp.GetPeer(onion)
the.EventBus = the.CwtchApp.GetEventBus(onion)

View File

@ -101,11 +101,6 @@ func IncomingListener(uiState *gothings.InterfaceState, subscribed chan bool) {
uiContact.Status = int(cxnState)
uiState.UpdateContact(contact.Onion)
}
// Stub reconnection-handler simply attempts reconnection
if cxnState == connections.DISCONNECTED {
the.Peer.PeerWithOnion(contact.Onion)
}
}
case event.ServerStateChange:
serverOnion := e.Data[event.GroupServer]