From 4b54b862720f68d1ee16e89384e370b04e78f659 Mon Sep 17 00:00:00 2001 From: Eason Lin Date: Wed, 2 Aug 2017 23:00:10 +0800 Subject: [PATCH] fix composite literal uses unkeyed fields warnings, #1050 (#1051) --- gin.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gin.go b/gin.go index 0372931..8347ce2 100644 --- a/gin.go +++ b/gin.go @@ -121,7 +121,7 @@ func New() *Engine { UseRawPath: false, UnescapePathValues: true, trees: make(methodTrees, 0, 9), - delims: render.Delims{"{{", "}}"}, + delims: render.Delims{Left: "{{", Right: "}}"}, secureJsonPrefix: "while(1);", } engine.RouterGroup.engine = engine @@ -143,7 +143,7 @@ func (engine *Engine) allocateContext() *Context { } func (engine *Engine) Delims(left, right string) *Engine { - engine.delims = render.Delims{left, right} + engine.delims = render.Delims{Left: left, Right: right} return engine }