@@ 57,12 57,15 @@ func (t *Template) tmplPayload(c echo.Context, data Map) (Map, error) {
}
// Now static variables
for k, v := range t.staticMap {
+ if _, ok := input[k]; ok {
+ return nil, fmt.Errorf("Template context conflict (static data). Reserved key: %v", k)
+ }
input[k] = v
}
if data != nil {
for k, v := range data {
if _, ok := input[k]; ok {
- return nil, fmt.Errorf("Template context conflict. Reserved key: %v", k)
+ return nil, fmt.Errorf("Template context conflict (handler data). Reserved key: %v", k)
}
input[k] = v
}