mirror of
https://github.com/thomiceli/opengist.git
synced 2025-06-13 05:47:12 +02:00
Include HTML buttons
This commit is contained in:
@ -163,7 +163,7 @@ func oauthCallback(ctx echo.Context) error {
|
||||
|
||||
if err = userDB.Create(); err != nil {
|
||||
if models.IsUniqueConstraintViolation(err) {
|
||||
addFlash(ctx, "Username "+user.NickName+" already exists in opengist", "error")
|
||||
addFlash(ctx, "Username "+user.NickName+" already exists in Opengist", "error")
|
||||
return redirect(ctx, "/login")
|
||||
}
|
||||
|
||||
|
@ -249,6 +249,9 @@ func dataInit(next echo.HandlerFunc) echo.HandlerFunc {
|
||||
}
|
||||
setData(ctx, "signupDisabled", disableSignup == "1")
|
||||
|
||||
setData(ctx, "githubOauth", config.C.GithubClientKey != "" && config.C.GithubSecret != "")
|
||||
setData(ctx, "giteaOauth", config.C.GiteaClientKey != "" && config.C.GiteaSecret != "")
|
||||
|
||||
return next(ctx)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user