mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-09-12 00:26:24 -04:00
fix bug
This commit is contained in:
parent
47de61b57c
commit
f495945b87
|
|
@ -212,7 +212,7 @@ func (self *View) LineCount(expectedCount int) *View {
|
|||
// if the view has a single blank line (often the case) we want to treat that as having no lines
|
||||
if len(lines) == 1 && expectedCount == 1 {
|
||||
actual := strings.TrimSpace(self.getView().Buffer())
|
||||
return actual == "", fmt.Sprintf("unexpected number of lines in view. Expected %d, got 0", expectedCount)
|
||||
return actual != "", "unexpected number of lines in view. Expected 1, got 0"
|
||||
}
|
||||
|
||||
return len(lines) == expectedCount, fmt.Sprintf("unexpected number of lines in view. Expected %d, got %d", expectedCount, len(lines))
|
||||
|
|
|
|||
Loading…
Reference in a new issue