mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-07-30 03:23:08 +03:00
standardise helper args
This commit is contained in:
@ -1,7 +1,6 @@
|
||||
package helpers
|
||||
|
||||
import (
|
||||
"github.com/jesseduffield/lazygit/pkg/commands"
|
||||
"github.com/jesseduffield/lazygit/pkg/commands/hosting_service"
|
||||
)
|
||||
|
||||
@ -13,17 +12,14 @@ type IHostHelper interface {
|
||||
}
|
||||
|
||||
type HostHelper struct {
|
||||
c *HelperCommon
|
||||
git *commands.GitCommand
|
||||
c *HelperCommon
|
||||
}
|
||||
|
||||
func NewHostHelper(
|
||||
c *HelperCommon,
|
||||
git *commands.GitCommand,
|
||||
) *HostHelper {
|
||||
return &HostHelper{
|
||||
c: c,
|
||||
git: git,
|
||||
c: c,
|
||||
}
|
||||
}
|
||||
|
||||
@ -39,7 +35,7 @@ func (self *HostHelper) GetCommitURL(commitSha string) (string, error) {
|
||||
// from one invocation to the next. Note however that we're currently caching config
|
||||
// results so we might want to invalidate the cache here if it becomes a problem.
|
||||
func (self *HostHelper) getHostingServiceMgr() *hosting_service.HostingServiceMgr {
|
||||
remoteUrl := self.git.Config.GetRemoteURL()
|
||||
remoteUrl := self.c.Git().Config.GetRemoteURL()
|
||||
configServices := self.c.UserConfig.Services
|
||||
return hosting_service.NewHostingServiceMgr(self.c.Log, self.c.Tr, remoteUrl, configServices)
|
||||
}
|
||||
|
Reference in New Issue
Block a user