diff --git a/ui/controller.go b/ui/controller.go index f3251d3..e9ba01b 100644 --- a/ui/controller.go +++ b/ui/controller.go @@ -144,12 +144,14 @@ func (c *controller) Listen(ctx context.Context, g *gocui.Gui, sub chan *events. c.models.RefreshInfo, c.models.RefreshWalletBalance, c.models.RefreshTransactions, + c.models.RefreshForwardingHistory, ) case events.ChannelBalanceUpdated: refresh( c.models.RefreshInfo, c.models.RefreshChannelsBalance, c.models.RefreshChannels, + c.models.RefreshForwardingHistory, ) case events.ChannelPending: refresh( @@ -174,11 +176,19 @@ func (c *controller) Listen(ctx context.Context, g *gocui.Gui, sub chan *events. c.models.RefreshInfo, c.models.RefreshChannelsBalance, c.models.RefreshChannels, + c.models.RefreshForwardingHistory, ) case events.PeerUpdated: - refresh(c.models.RefreshInfo) + refresh( + c.models.RefreshInfo, + c.models.RefreshForwardingHistory, + ) + case events.RoutingEventUpdated: - refresh(c.models.RefreshRouting(event.Data)) + refresh( + c.models.RefreshRouting(event.Data), + c.models.RefreshForwardingHistory, + ) case events.GraphUpdated: refresh(c.models.RefreshPolicies(event.Data)) } @@ -300,9 +310,7 @@ func (c *controller) OnEnter(g *gocui.Gui, v *gocui.View) error { if err != nil { return err } - ctx, cancel := context.WithTimeout(context.Background(), time.Second*60) - defer cancel() - c.models.RefreshForwardingHistory(ctx) + c.views.Main = c.views.FwdingHist err = c.views.FwdingHist.Set(g, 11, 6, maxX-1, maxY) if err != nil {