diff --git a/pkg/core/eiblog/file/timer.go b/pkg/core/eiblog/file/timer.go index cf12534..2617d68 100644 --- a/pkg/core/eiblog/file/timer.go +++ b/pkg/core/eiblog/file/timer.go @@ -21,7 +21,8 @@ func init() { var err error xmlTmpl, err = template.New("").Funcs(template.FuncMap{ - "dateformat": tools.DateFormat, + "dateformat": tools.DateFormat, + "imgtonormal": tools.ImgToNormal, }).ParseGlob(root) if err != nil { panic(err) diff --git a/tools/tmplfunc.go b/tools/tmplfunc.go index f7abf8b..fcbb940 100644 --- a/tools/tmplfunc.go +++ b/tools/tmplfunc.go @@ -25,7 +25,6 @@ func init() { TplFuncMap["join"] = Join TplFuncMap["isnotzero"] = IsNotZero TplFuncMap["getavatar"] = GetAvatar - TplFuncMap["imgtonormal"] = ImgToNormal } // Str2html string to html