Skip to content

Commit

Permalink
bugfix for trim_right/left function in template
Browse files Browse the repository at this point in the history
  • Loading branch information
mylxsw committed Aug 19, 2020
1 parent c271df9 commit 4d0fdb8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
16 changes: 8 additions & 8 deletions api/static.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions pkg/template/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ func CreateParser(templateStr string) (*template.Template, error) {
"starts_with": startsWith,
"ends_with": endsWith,
"trim": strings.Trim,
"trim_right": strings.TrimRight,
"trim_left": strings.TrimLeft,
"trim_right": strings.TrimSuffix,
"trim_left": strings.TrimPrefix,
"trim_space": strings.TrimSpace,
"format": fmt.Sprintf,
"integer": toInteger,
Expand Down

0 comments on commit 4d0fdb8

Please sign in to comment.