mirror of
https://github.com/go-gitea/gitea
synced 2025-07-23 02:38:35 +00:00
Add TestPrepareWikiFileName (#16487)
* Add TestPrepareWikiFileName * use LsTree as LsFiles is index only * ajust other tests Co-authored-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
@@ -88,7 +88,7 @@ func prepareWikiFileName(gitRepo *git.Repository, wikiName string) (bool, string
|
||||
escaped := NameToFilename(wikiName)
|
||||
|
||||
// Look for both files
|
||||
filesInIndex, err := gitRepo.LsFiles(unescaped, escaped)
|
||||
filesInIndex, err := gitRepo.LsTree("master", unescaped, escaped)
|
||||
if err != nil {
|
||||
log.Error("%v", err)
|
||||
return false, escaped, err
|
||||
|
Reference in New Issue
Block a user