Don't pass ignoreWhitespace to git commands

Now that AppState is available via common.Common, they can take it from there.
This commit is contained in:
Stefan Haller 2023-08-28 12:39:52 +02:00
parent 18c5780485
commit 1dac4158e9
16 changed files with 40 additions and 45 deletions

View file

@ -196,7 +196,7 @@ func (self *CommitCommands) AmendHeadCmdObj() oscommands.ICmdObj {
return self.cmd.New(cmdArgs)
}
func (self *CommitCommands) ShowCmdObj(sha string, filterPath string, ignoreWhitespace bool) oscommands.ICmdObj {
func (self *CommitCommands) ShowCmdObj(sha string, filterPath string) oscommands.ICmdObj {
contextSize := self.UserConfig.Git.DiffContextSize
extDiffCmd := self.UserConfig.Git.Paging.ExternalDiffCommand
@ -210,7 +210,7 @@ func (self *CommitCommands) ShowCmdObj(sha string, filterPath string, ignoreWhit
Arg("--decorate").
Arg("-p").
Arg(sha).
ArgIf(ignoreWhitespace, "--ignore-all-space").
ArgIf(self.AppState.IgnoreWhitespaceInDiffView, "--ignore-all-space").
ArgIf(filterPath != "", "--", filterPath).
ToArgv()