From 1b778509c9209ba895e5ff51b47b23f2ea3b7a22 Mon Sep 17 00:00:00 2001 From: "asta.xie" Date: Sat, 8 Feb 2014 10:42:34 +0800 Subject: [PATCH] should copy the data direct. don't need range --- controller.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/controller.go b/controller.go index 38e57b59..9bd68ae8 100644 --- a/controller.go +++ b/controller.go @@ -76,9 +76,7 @@ func (c *Controller) Init(ctx *context.Context, controllerName, actionName strin c.TplExt = "tpl" c.AppController = app c.EnableReander = true - for k, v := range ctx.Input.Data { - c.Data[k] = v - } + c.Data = ctx.Input.Data } // Prepare runs after Init before request function execution.