mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-31 22:41:53 +02:00
@@ -26,10 +26,12 @@ func New() *Namespace {
|
||||
type Namespace struct {
|
||||
}
|
||||
|
||||
// ToInt converts the given value to an int.
|
||||
func (ns *Namespace) ToInt(v interface{}) (int, error) {
|
||||
return _cast.ToIntE(v)
|
||||
}
|
||||
|
||||
// ToString converts the given value to a string.
|
||||
func (ns *Namespace) ToString(v interface{}) (string, error) {
|
||||
return _cast.ToStringE(v)
|
||||
}
|
||||
|
@@ -25,7 +25,7 @@ func init() {
|
||||
docs := make(map[string]interface{})
|
||||
d := &deps.Deps{}
|
||||
|
||||
var namespaces []*internal.TemplateFuncsNamespace
|
||||
var namespaces internal.TemplateFuncsNamespaces
|
||||
|
||||
for _, nsf := range internal.TemplateFuncsNamespaceRegistry {
|
||||
nf := nsf(d)
|
||||
|
Reference in New Issue
Block a user