1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-28 16:02:01 +03:00

don't needlessly load every file

This commit is contained in:
Jesse Duffield
2020-08-22 17:17:08 +10:00
parent 8be970e688
commit 30a555b108
2 changed files with 6 additions and 11 deletions

View File

@ -1077,12 +1077,7 @@ func (c *GitCommand) GetCommitFilesFromFilenames(filenames string, parent string
for _, file := range strings.Split(strings.TrimRight(filenames, "\n"), "\n") {
status := patch.UNSELECTED
if patchManager != nil && patchManager.Parent == parent {
var err error
status, err = patchManager.GetFileStatus(file)
if err != nil {
c.Log.Error(err)
continue
}
status = patchManager.GetFileStatus(file)
}
commitFiles = append(commitFiles, &CommitFile{