summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUnknwon <joe2010xtmf@163.com>2015-02-14 17:01:33 -0500
committerUnknwon <joe2010xtmf@163.com>2015-02-14 17:01:33 -0500
commit685ed1f8075c0fedc2cfaf0f8c43f9439132e1da (patch)
tree29eef97c91612d15bd56ee4bf06d0df98083b6ba
parenta38e4a0b027f7be1f5523dc8e729f6f8300a8095 (diff)
downloadgitea-685ed1f8075c0fedc2cfaf0f8c43f9439132e1da.tar.gz
gitea-685ed1f8075c0fedc2cfaf0f8c43f9439132e1da.zip
models: fix XORM API break
cmd/web.go: check version after load config
-rw-r--r--cmd/web.go3
-rw-r--r--gogs.go2
-rw-r--r--models/models.go2
-rw-r--r--templates/.VERSION2
4 files changed, 4 insertions, 5 deletions
diff --git a/cmd/web.go b/cmd/web.go
index 3284acb9df..4b06a882c0 100644
--- a/cmd/web.go
+++ b/cmd/web.go
@@ -166,12 +166,11 @@ func newMacaron() *macaron.Macaron {
}
func runWeb(ctx *cli.Context) {
- checkVersion()
-
if ctx.IsSet("config") {
setting.CustomConf = ctx.String("config")
}
routers.GlobalInit()
+ checkVersion()
m := newMacaron()
diff --git a/gogs.go b/gogs.go
index 76c6c71fc3..34790b7258 100644
--- a/gogs.go
+++ b/gogs.go
@@ -17,7 +17,7 @@ import (
"github.com/gogits/gogs/modules/setting"
)
-const APP_VER = "0.5.13.0212 Beta"
+const APP_VER = "0.5.13.0214 Beta"
func init() {
runtime.GOMAXPROCS(runtime.NumCPU())
diff --git a/models/models.go b/models/models.go
index 35e803834c..486aceac22 100644
--- a/models/models.go
+++ b/models/models.go
@@ -121,7 +121,7 @@ func SetEngine() (err error) {
if err != nil {
return fmt.Errorf("models.init(fail to create xorm.log): %v", err)
}
- x.Logger = xorm.NewSimpleLogger(f)
+ x.SetLogger(xorm.NewSimpleLogger(f))
x.ShowSQL = true
x.ShowInfo = true
diff --git a/templates/.VERSION b/templates/.VERSION
index 6d13155b02..0c9421a4d2 100644
--- a/templates/.VERSION
+++ b/templates/.VERSION
@@ -1 +1 @@
-0.5.13.0212 Beta \ No newline at end of file
+0.5.13.0214 Beta \ No newline at end of file