1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-06-23 00:39:13 +02:00

move remotes loader into loaders package

This commit is contained in:
Jesse Duffield
2021-12-30 17:36:21 +11:00
parent d69ce7a529
commit 44b6d26b10
3 changed files with 27 additions and 5 deletions

View File

@ -4,6 +4,7 @@ import (
"fmt"
"strings"
"github.com/jesseduffield/lazygit/pkg/commands/loaders"
"github.com/jesseduffield/lazygit/pkg/commands/models"
"github.com/jesseduffield/lazygit/pkg/gui/style"
"github.com/jesseduffield/lazygit/pkg/utils"
@ -40,7 +41,7 @@ func (gui *Gui) remotesRenderToMain() error {
func (gui *Gui) refreshRemotes() error {
prevSelectedRemote := gui.getSelectedRemote()
remotes, err := gui.GitCommand.GetRemotes()
remotes, err := loaders.NewRemoteLoader(gui.Common, gui.GitCommand.Cmd, gui.GitCommand.Repo.Remotes).GetRemotes()
if err != nil {
return gui.surfaceError(err)
}