1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-11-25 22:32:13 +02:00

fix: fix a crash when pressing enter in empty commits, reflog, or stash panel

This commit is contained in:
Ryooooooga
2022-05-05 21:41:44 +09:00
parent f143d04d87
commit 2eb866fc62
7 changed files with 35 additions and 7 deletions

View File

@@ -62,5 +62,9 @@ func (self *StashContext) CanRebase() bool {
}
func (self *StashContext) GetSelectedRef() types.Ref {
return self.GetSelected()
stash := self.GetSelected()
if stash == nil {
return nil
}
return stash
}