summaryrefslogtreecommitdiffstats
path: root/routers/init.go
diff options
context:
space:
mode:
authorLauris BH <lauris@nix.lv>2018-04-29 09:09:24 +0300
committerGitHub <noreply@github.com>2018-04-29 09:09:24 +0300
commit5a62eb30df3a04e76e465824f525b4ffd920b562 (patch)
treec3410d159a14a6b6d36b2ffadebbfb7dd48617f9 /routers/init.go
parent8d5f58d8347196fca04fdf3a22d021d09d15e37f (diff)
downloadgitea-5a62eb30df3a04e76e465824f525b4ffd920b562.tar.gz
gitea-5a62eb30df3a04e76e465824f525b4ffd920b562.zip
Store OAuth2 session data in database (#3660)
* Store OAuth2 session data in database * Rename table to `oauth2_session` and do not skip xormstorage initialization error
Diffstat (limited to 'routers/init.go')
-rw-r--r--routers/init.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/routers/init.go b/routers/init.go
index 3ed5fc4f58..a52f9ca1b4 100644
--- a/routers/init.go
+++ b/routers/init.go
@@ -60,7 +60,9 @@ func GlobalInit() {
log.Fatal(4, "Failed to initialize ORM engine: %v", err)
}
models.HasEngine = true
- models.InitOAuth2()
+ if err := models.InitOAuth2(); err != nil {
+ log.Fatal(4, "Failed to initialize OAuth2 support: %v", err)
+ }
models.LoadRepoConfig()
models.NewRepoContext()