Browse Source

Added functionality to check if a static template bundle file is being used. No need to register the cog template in this scenario.

Wirecog 7 years ago
parent
commit
fa3ba1a2d3
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      uxcog.go

+ 6
- 0
uxcog.go View File

62
 }
62
 }
63
 
63
 
64
 func (u *UXCog) CogInit(ts *isokit.TemplateSet) {
64
 func (u *UXCog) CogInit(ts *isokit.TemplateSet) {
65
+
65
 	u.hasBeenRendered = false
66
 	u.hasBeenRendered = false
66
 	u.Props = make(map[string]interface{})
67
 	u.Props = make(map[string]interface{})
67
 	if ts != nil {
68
 	if ts != nil {
71
 	u.cogPrefixName = u.getCogPrefixName()
72
 	u.cogPrefixName = u.getCogPrefixName()
72
 
73
 
73
 	if isokit.OperatingEnvironment() == isokit.ServerEnvironment {
74
 	if isokit.OperatingEnvironment() == isokit.ServerEnvironment {
75
+
76
+		if isokit.UseStaticTemplateBundleFile == true {
77
+			return
78
+		}
79
+
74
 		u.RegisterCogTemplates()
80
 		u.RegisterCogTemplates()
75
 	}
81
 	}
76
 }
82
 }