From 0f42c42547c9afb05f878b4f4d1c45d657f35f07 Mon Sep 17 00:00:00 2001 From: Ayman Bagabas Date: Fri, 20 May 2022 12:04:24 -0400 Subject: [PATCH] fix: no repos --- ui/pages/selection/selection.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ui/pages/selection/selection.go b/ui/pages/selection/selection.go index bb4a6ba93e5cd4e3584b8bffd984685f75c312f4..cc8659cb495cf179d619edbc1a06cac41133f589 100644 --- a/ui/pages/selection/selection.go +++ b/ui/pages/selection/selection.go @@ -261,7 +261,11 @@ func (s *Selection) View() string { } func (s *Selection) changeActive(msg selector.ActiveMsg) tea.Cmd { - r := msg.IdentifiableItem.(Item).repo + item, ok := msg.IdentifiableItem.(Item) + if !ok { + return nil + } + r := item.repo rm, rp := r.Readme() return s.readme.SetContent(rm, rp) }