summaryrefslogtreecommitdiffstats
path: root/pkg/gui/global_handlers.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2020-08-23 21:25:39 +1000
committergithub-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>2020-08-23 11:30:29 +0000
commit0f7003d939a969920ffdb5f2d28fca2fd0eb7f65 (patch)
treebb245de541583ea37e9a656d16689b55035402de /pkg/gui/global_handlers.go
parentd2d88fe64e1fb3b831b283c56294271323bcade1 (diff)
allow spamming the p key
Diffstat (limited to 'pkg/gui/global_handlers.go')
-rw-r--r--pkg/gui/global_handlers.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/pkg/gui/global_handlers.go b/pkg/gui/global_handlers.go
index 1129f63fd..d5b25f738 100644
--- a/pkg/gui/global_handlers.go
+++ b/pkg/gui/global_handlers.go
@@ -165,6 +165,9 @@ func (gui *Gui) handleInfoClick(g *gocui.Gui, v *gocui.View) error {
}
func (gui *Gui) fetch(canPromptForCredentials bool) (err error) {
+ gui.State.FetchMutex.Lock()
+ defer gui.State.FetchMutex.Unlock()
+
fetchOpts := commands.FetchOptions{}
if canPromptForCredentials {
fetchOpts.PromptUserForCredential = gui.promptUserForCredential