Fix install bugs
This commit is contained in:
parent
9f91dee53f
commit
3698431fc1
2 changed files with 19 additions and 0 deletions
|
@ -21,6 +21,11 @@ type ToggleOptions struct {
|
|||
|
||||
func Toggle(options *ToggleOptions) martini.Handler {
|
||||
return func(ctx *Context) {
|
||||
if !base.InstallLock {
|
||||
ctx.Redirect("/install")
|
||||
return
|
||||
}
|
||||
|
||||
if options.SignOutRequire && ctx.IsSigned && ctx.Req.RequestURI != "/" {
|
||||
ctx.Redirect("/")
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue