tpl/time: Remove asTime template func mapping - hugo - [fork] hugo port for 9front
HTML git clone git@git.drkhsh.at/hugo.git
DIR Log
DIR Files
DIR Refs
DIR Submodules
DIR README
DIR LICENSE
---
DIR commit a59525b05b071de020ecc457c94ad0a987040d93
DIR parent 3954160a21bcde7d4f4c077f9cc9daa610f3e29e
HTML Author: Cameron Moore <moorereason@gmail.com>
Date: Wed, 17 May 2017 14:26:02 -0500
tpl/time: Remove asTime template func mapping
Diffstat:
M tpl/time/init.go | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
---
DIR diff --git a/tpl/time/init.go b/tpl/time/init.go
@@ -32,8 +32,7 @@ func init() {
// If no args are passed to `time`, assume namespace usage and
// return namespace context.
//
- // If args are passed, show a deprecation warning and attempt to
- // simulate the old "as time" behavior.
+ // If args are passed, call AsTime().
if len(v) == 0 {
return ctx
@@ -59,13 +58,6 @@ func init() {
[][2]string{},
)
- ns.AddMethodMapping(ctx.AsTime,
- []string{"asTime"},
- [][2]string{
- {`{{ (asTime "2015-01-21").Year }}`, `2015`},
- },
- )
-
return ns
}