File tree 1 file changed +7
-6
lines changed
Filter options
1 file changed +7
-6
lines changed
Original file line number Diff line number Diff line change @@ -90,19 +90,20 @@ func Run(port int) {
90
90
MainTemplateLoader = NewTemplateLoader (TemplatePaths )
91
91
MainTemplateLoader .Refresh ()
92
92
93
- // If desired (or by default), create a watcher for templates and routes.
94
- // The watcher calls Refresh() on things on the first request.
95
- if MainWatcher != nil && Config .BoolDefault ("watch.templates" , true ) {
96
- MainWatcher .Listen (MainTemplateLoader , MainTemplateLoader .paths ... )
97
- }
98
-
99
93
// The "watch" config variable can turn on and off all watching.
100
94
// (As a convenient way to control it all together.)
101
95
if Config .BoolDefault ("watch" , true ) {
102
96
MainWatcher = NewWatcher ()
103
97
Filters = append ([]Filter {WatchFilter }, Filters ... )
104
98
}
105
99
100
+ // If desired (or by default), create a watcher for templates and routes.
101
+ // The watcher calls Refresh() on things on the first request.
102
+ if MainWatcher != nil && Config .BoolDefault ("watch.templates" , true ) {
103
+ WARN .Println ("watch templates true" )
104
+ MainWatcher .Listen (MainTemplateLoader , MainTemplateLoader .paths ... )
105
+ }
106
+
106
107
go func () {
107
108
time .Sleep (100 * time .Millisecond )
108
109
fmt .Printf ("Listening on %s...\n " , localAddress )
You can’t perform that action at this time.
0 commit comments