mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-07-30 03:23:08 +03:00
fix: fix a crash when pressing enter in empty commits, reflog, or stash panel
This commit is contained in:
@ -58,5 +58,9 @@ func (self *BranchesContext) GetSelectedItemId() string {
|
||||
}
|
||||
|
||||
func (self *BranchesContext) GetSelectedRef() types.Ref {
|
||||
return self.GetSelected()
|
||||
branch := self.GetSelected()
|
||||
if branch == nil {
|
||||
return nil
|
||||
}
|
||||
return branch
|
||||
}
|
||||
|
Reference in New Issue
Block a user