Skip to content

Commit c7b1573

Browse files
修复定时任务不能执行的BUG
2 parents 1c2584c + c4658cc commit c7b1573

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

main.go

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,7 @@ import (
77
"github.com/astaxie/beego"
88
)
99

10-
// 初始化一些配置
11-
func setting() {
12-
13-
// 初始化获取命令行参数
14-
common.InitCli()
10+
func main() {
1511

1612
// 是否启用 定时生成验证密码 功能
1713
if ok, _ := beego.AppConfig.Bool("authpassword::enableCrontabAuthPassword"); ok {
@@ -22,11 +18,8 @@ func setting() {
2218
if ok, _ := beego.AppConfig.Bool("authpassword::enableManualGenAuthPassword"); ok {
2319
common.CronClearAuthPassword()
2420
}
25-
}
2621

27-
func main() {
28-
29-
// 设置
30-
setting()
22+
// 初始化获取命令行参数
23+
common.InitCli()
3124

3225
}

0 commit comments

Comments
 (0)