change func name initial=>lazyInitial in web service package

pull/199/head
Michael Li 3 years ago
parent 70b53ffede
commit e6414f66ff
No known key found for this signature in database

@ -24,7 +24,7 @@ var (
// RouteWeb register web route // RouteWeb register web route
func RouteWeb(e *gin.Engine) { func RouteWeb(e *gin.Engine) {
initial() lazyInitial()
oss := dao.ObjectStorageService() oss := dao.ObjectStorageService()
ds := &base.DaoServant{ ds := &base.DaoServant{
Redis: conf.Redis, Redis: conf.Redis,
@ -75,8 +75,8 @@ func mustAlipayClient() *alipay.Client {
return client return client
} }
// initial do some package lazy initialize for performance // lazyInitial do some package lazy initialize for performance
func initial() { func lazyInitial() {
_onceInitial.Do(func() { _onceInitial.Do(func() {
_EnablePhoneVerify = cfg.If("Sms") _EnablePhoneVerify = cfg.If("Sms")
}) })

Loading…
Cancel
Save