Skip to content

Commit 0d10482

Browse files
guillep2kzeripath
authored andcommitted
Fixes indexed repos keeping outdated indexes when files grow too large (#7731)
* Fixes indexed repos keeping outdated indexes when files grow too large Co-Authored-By: zeripath <[email protected]>
1 parent 6d441de commit 0d10482

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

models/repo_indexer.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ func addUpdate(update fileUpdate, repo *Repository, batch rupture.FlushingBatch)
199199
if size, err := strconv.Atoi(strings.TrimSpace(stdout)); err != nil {
200200
return fmt.Errorf("Misformatted git cat-file output: %v", err)
201201
} else if int64(size) > setting.Indexer.MaxIndexerFileSize {
202-
return nil
202+
return addDelete(update.Filename, repo, batch)
203203
}
204204

205205
fileContents, err := git.NewCommand("cat-file", "blob", update.BlobSha).

0 commit comments

Comments
 (0)