mirror of https://github.com/MedzikUser/go-pingbot
chore: move db connect under opts param
This commit is contained in:
parent
4a4505c1f2
commit
d728e96d82
4
main.go
4
main.go
|
@ -27,8 +27,6 @@ func main() {
|
||||||
|
|
||||||
var wg sync.WaitGroup
|
var wg sync.WaitGroup
|
||||||
|
|
||||||
mongo.Connect()
|
|
||||||
|
|
||||||
c := cmdOpts{}
|
c := cmdOpts{}
|
||||||
|
|
||||||
opts.Parse(&c)
|
opts.Parse(&c)
|
||||||
|
@ -88,6 +86,8 @@ func main() {
|
||||||
os.Exit(0)
|
os.Exit(0)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mongo.Connect()
|
||||||
|
|
||||||
if config.Toml.AutoUpdate.Enabled {
|
if config.Toml.AutoUpdate.Enabled {
|
||||||
wg.Add(1)
|
wg.Add(1)
|
||||||
|
|
Loading…
Reference in New Issue