1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-28 16:02:01 +03:00

Address PR comments

This commit is contained in:
Joel Baranick
2022-09-10 22:36:47 -07:00
committed by Jesse Duffield
parent 1ce9a87544
commit db02c13bf6
7 changed files with 74 additions and 67 deletions

View File

@ -63,7 +63,7 @@ func (self *WorktreesController) GetOnRenderToMain() func() error {
}
missing := ""
if worktree.Missing() {
if self.c.Git().Worktree.IsWorktreePathMissing(worktree) {
missing = style.FgRed.Sprintf(" %s", self.c.Tr.MissingWorktree)
}
@ -112,7 +112,7 @@ func (self *WorktreesController) delete(worktree *models.Worktree) error {
return self.c.ErrorMsg(self.c.Tr.CantDeleteMainWorktree)
}
if worktree.Current() {
if self.c.Git().Worktree.IsCurrentWorktree(worktree) {
return self.c.ErrorMsg(self.c.Tr.CantDeleteCurrentWorktree)
}