1.4.5.2
This commit is contained in:
17
EdgeAdmin/internal/web/actions/default/setup/helper.go
Normal file
17
EdgeAdmin/internal/web/actions/default/setup/helper.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package setup
|
||||
|
||||
import (
|
||||
"github.com/TeaOSLab/EdgeAdmin/internal/setup"
|
||||
"github.com/iwind/TeaGo/actions"
|
||||
)
|
||||
|
||||
type Helper struct {
|
||||
}
|
||||
|
||||
func (this *Helper) BeforeAction(actionPtr actions.ActionWrapper) (goNext bool) {
|
||||
if setup.IsConfigured() {
|
||||
actionPtr.Object().RedirectURL("/")
|
||||
return false
|
||||
}
|
||||
return true
|
||||
}
|
||||
Reference in New Issue
Block a user