mirror of
https://github.com/go-gitea/gitea
synced 2025-07-05 18:17:19 +00:00
Move git diff codes from models to services/gitdiff (#7889)
* move git diff codes from models to services/gitdiff * fix template * fix test * fix template
This commit is contained in:
committed by
techknowlogick
parent
b660a732ae
commit
c03d75fbd5
@ -27,6 +27,7 @@ import (
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
"code.gitea.io/gitea/modules/timeutil"
|
||||
"code.gitea.io/gitea/modules/util"
|
||||
"code.gitea.io/gitea/services/gitdiff"
|
||||
|
||||
"gopkg.in/editorconfig/editorconfig-core-go.v1"
|
||||
)
|
||||
@ -230,6 +231,7 @@ func NewFuncMap() []template.FuncMap {
|
||||
}
|
||||
return float32(n) * 100 / float32(sum)
|
||||
},
|
||||
"CommentMustAsDiff": gitdiff.CommentMustAsDiff,
|
||||
}}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user