aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ui
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ui')
-rw-r--r--lib/ui/tab.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ui/tab.go b/lib/ui/tab.go
index 2ab703ab..ed96ec40 100644
--- a/lib/ui/tab.go
+++ b/lib/ui/tab.go
@@ -102,7 +102,7 @@ func (tabs *Tabs) removeHistory(index int) {
item = item - 1
}
// dedup
- if i > 0 && item == newHist[len(newHist)-1] {
+ if i > 0 && len(newHist) > 0 && item == newHist[len(newHist)-1] {
continue
}
newHist = append(newHist, item)