Update routers/web/repo/view_file.go

Co-authored-by: yp05327 <576951401@qq.com>
This commit is contained in:
wxiaoguang 2025-04-11 20:13:33 +08:00 committed by GitHub
parent a0cfb36717
commit fca3bcf0d9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -159,7 +159,7 @@ func prepareToRenderFile(ctx *context.Context, entry *git.TreeEntry) {
}
attrs := attrsMap[ctx.Repo.TreePath]
if attrs == nil {
// this case shouldn't happe, just in case.
// this case shouldn't happen, just in case.
setting.PanicInDevOrTesting("no attributes found for %s", ctx.Repo.TreePath)
attrs = attribute.NewAttributes()
}