mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 14:40:57 +00:00
AutoRender为空时,不再编译模版
AutoRender为空,Controller.Render()不再执行,故无需编译模版
This commit is contained in:
parent
4857e38471
commit
57fdc308e3
10
beego.go
10
beego.go
@ -307,10 +307,12 @@ func initBeforeHttpRun() {
|
|||||||
go GlobalSessions.GC()
|
go GlobalSessions.GC()
|
||||||
}
|
}
|
||||||
|
|
||||||
err := BuildTemplate(ViewsPath)
|
if AutoRender {
|
||||||
if err != nil {
|
err := BuildTemplate(ViewsPath)
|
||||||
if RunMode == "dev" {
|
if err != nil {
|
||||||
Warn(err)
|
if RunMode == "dev" {
|
||||||
|
Warn(err)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user