diff --git a/pkg/gui/branches_panel.go b/pkg/gui/branches_panel.go index 43c585730..7d1ca5782 100644 --- a/pkg/gui/branches_panel.go +++ b/pkg/gui/branches_panel.go @@ -34,8 +34,7 @@ func (gui *Gui) handleCreatePullRequestPress(g *gocui.Gui, v *gocui.View) error } func (gui *Gui) handleGitFetch(g *gocui.Gui, v *gocui.View) error { - _ = gui.fetch(g, true) - return nil + return gui.fetch(g, v, true) } func (gui *Gui) handleForceCheckout(g *gocui.Gui, v *gocui.View) error { diff --git a/pkg/gui/gui.go b/pkg/gui/gui.go index 767a25bde..aab73e738 100644 --- a/pkg/gui/gui.go +++ b/pkg/gui/gui.go @@ -371,9 +371,9 @@ func (gui *Gui) promptAnonymousReporting() error { }) } -func (gui *Gui) fetch(g *gocui.Gui, canSskForCredentials bool) error { +func (gui *Gui) fetch(g *gocui.Gui, v *gocui.View, canSskForCredentials bool) error { err := gui.GitCommand.Fetch(func(passOrUname string) string { - return gui.waitForPassUname(gui.g, gui.g.CurrentView(), passOrUname) + return gui.waitForPassUname(gui.g, v, passOrUname) }, canSskForCredentials) if canSskForCredentials && err != nil && strings.Contains(err.Error(), "exit status 128") { @@ -382,7 +382,7 @@ func (gui *Gui) fetch(g *gocui.Gui, canSskForCredentials bool) error { close := func(g *gocui.Gui, v *gocui.View) error { return nil } - _ = gui.createConfirmationPanel(g, g.CurrentView(), gui.Tr.SLocalize("Error"), coloredMessage, close, close) + _ = gui.createConfirmationPanel(g, v, gui.Tr.SLocalize("Error"), coloredMessage, close, close) } gui.refreshStatus(g) @@ -442,12 +442,12 @@ func (gui *Gui) Run() error { } go func() { - err := gui.fetch(g, false) + err := gui.fetch(g, g.CurrentView(), false) if err != nil && strings.Contains(err.Error(), "exit status 128") { _ = gui.createConfirmationPanel(g, g.CurrentView(), gui.Tr.SLocalize("NoAutomaticGitFetchTitle"), gui.Tr.SLocalize("NoAutomaticGitFetchBody"), nil, nil) } else { gui.goEvery(g, time.Second*60, func(g *gocui.Gui) error { - return gui.fetch(g, false) + return gui.fetch(g, g.CurrentView(), false) }) } }() diff --git a/pkg/i18n/dutch.go b/pkg/i18n/dutch.go index afc20d32b..a29c8c8c0 100644 --- a/pkg/i18n/dutch.go +++ b/pkg/i18n/dutch.go @@ -417,10 +417,10 @@ func addDutch(i18nObject *i18n.Bundle) error { Other: `fetch`, }, &i18n.Message{ ID: "NoAutomaticGitFetchTitle", - Other: `No automatic git fetch`, + Other: `Geen automatiese git fetch`, }, &i18n.Message{ ID: "NoAutomaticGitFetchBody", - Other: `Lazygit can't use "git fetch" in a private repo use f in the branches panel to run git fetch manually`, + Other: `Lazygit kan niet "git fetch" uitvoeren in een privé repository, gebruik f in het branches paneel om "git fetch" manueel uit te voeren`, }, &i18n.Message{ ID: "StageLines", Other: `stage individual hunks/lines`, diff --git a/pkg/i18n/english.go b/pkg/i18n/english.go index 9ca6af074..872e9783e 100644 --- a/pkg/i18n/english.go +++ b/pkg/i18n/english.go @@ -428,7 +428,7 @@ func addEnglish(i18nObject *i18n.Bundle) error { Other: `No automatic git fetch`, }, &i18n.Message{ ID: "NoAutomaticGitFetchBody", - Other: `Lazygit can't use "git fetch" in a private repo use f in the branches panel to run git fetch manually`, + Other: `Lazygit can't use "git fetch" in a private repo use f in the branches panel to run "git fetch" manually`, }, &i18n.Message{ ID: "StageLines", Other: `stage individual hunks/lines`, diff --git a/pkg/i18n/polish.go b/pkg/i18n/polish.go index 271282c5b..3ffa980ae 100644 --- a/pkg/i18n/polish.go +++ b/pkg/i18n/polish.go @@ -403,7 +403,7 @@ func addPolish(i18nObject *i18n.Bundle) error { Other: `No automatic git fetch`, }, &i18n.Message{ ID: "NoAutomaticGitFetchBody", - Other: `Lazygit can't use "git fetch" in a private repo use f in the branches panel to run git fetch manually`, + Other: `Lazygit can't use "git fetch" in a private repo use f in the branches panel to run "git fetch" manually`, }, &i18n.Message{ ID: "StageLines", Other: `stage individual hunks/lines`,