Skip to content

Commit 31842f1

Browse files
authored
Add MD5 back to template helper functions to avoid breaking (#21102)
In #20932 the MD5 helper function was removed from template context, it breaks user's customized templates. This PR adds the MD5 helper function back.
1 parent 32eef4a commit 31842f1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

modules/templates/helper.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ func NewFuncMap() []template.FuncMap {
154154
"DiffTypeToStr": DiffTypeToStr,
155155
"DiffLineTypeToStr": DiffLineTypeToStr,
156156
"ShortSha": base.ShortSha,
157+
"MD5": base.EncodeMD5,
157158
"ActionContent2Commits": ActionContent2Commits,
158159
"PathEscape": url.PathEscape,
159160
"PathEscapeSegments": util.PathEscapeSegments,

0 commit comments

Comments
 (0)