MCPcopy Create free account
hub / github.com/kataras/iris / initSet

Method initSet

view/django.go:278–283  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

276}
277
278func (s *DjangoEngine) initSet() { // protected by the caller.
279 if s.Set == nil {
280 s.Set = pongo2.NewSet("", &tDjangoAssetLoader{fs: s.fs, rootDir: s.rootDir})
281 s.Set.Globals = getPongoContext(s.globals)
282 }
283}
284
285// getPongoContext returns the pongo2.Context from map[string]interface{} or from pongo2.Context, used internaly
286func getPongoContext(templateData interface{}) pongo2.Context {

Callers 1

ParseTemplateMethod · 0.95

Calls 1

getPongoContextFunction · 0.85

Tested by

no test coverage detected