Skip to content

Commit

Permalink
gtemplate
Browse files Browse the repository at this point in the history
  • Loading branch information
snail007 committed Dec 19, 2023
1 parent e1f41c2 commit d1ab916
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions http/template/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,6 @@ func RenderString(tpl string, data map[string]interface{}) (result string, err e
}

func RenderStringWithFunc(tpl string, data map[string]interface{}, funcMap map[string]interface{}) (result string, err error) {
r, err := RenderBytesWithFunc([]byte(tpl), data, funcMap)
if err != nil {
return
}
return string(r), nil
r, e := RenderBytesWithFunc([]byte(tpl), data, funcMap)
return string(r), e
}

0 comments on commit d1ab916

Please sign in to comment.