Un-lambda base.FileSize (#7556)

No need to wrap this.
tokarchuk/v1.17
Christian Muehlhaeuser 6 years ago committed by Lauris BH
parent 12a098920c
commit 9a965035f0
  1. 6
      modules/templates/helper.go

@ -93,10 +93,8 @@ func NewFuncMap() []template.FuncMap {
"DateFmtShort": func(t time.Time) string { "DateFmtShort": func(t time.Time) string {
return t.Format("Jan 02, 2006") return t.Format("Jan 02, 2006")
}, },
"SizeFmt": func(s int64) string { "SizeFmt": base.FileSize,
return base.FileSize(s) "List": List,
},
"List": List,
"SubStr": func(str string, start, length int) string { "SubStr": func(str string, start, length int) string {
if len(str) == 0 { if len(str) == 0 {
return "" return ""

Loading…
Cancel
Save