Browse Source

updsate

master
dengbiao 2 weeks ago
parent
commit
17b736995b
2 changed files with 9 additions and 1 deletions
  1. +1
    -1
      rule/egg_energy/give_activty_coin.go
  2. +8
    -0
      svc/svc_file_img_format.go

+ 1
- 1
rule/egg_energy/give_activty_coin.go View File

@@ -69,7 +69,7 @@ func SettlementGiveActivityCoin(engine *xorm.Engine, user model.User, ecpm strin
redisConn := cache.GetPool().Get()
sysCfgDb := implement.NewSysCfgDb(engine, redisConn)
defer func(sysCfgDb dao.SysCfgDao) {
err := sysCfgDb.Close()
err = sysCfgDb.Close()
if err != nil {
fmt.Println("redis close err:" + err.Error()) // 记录错误信息
}


+ 8
- 0
svc/svc_file_img_format.go View File

@@ -1,8 +1,10 @@
package svc

import (
"code.fnuoos.com/EggPlanet/egg_models.git/src/dao"
"code.fnuoos.com/EggPlanet/egg_models.git/src/implement"
"code.fnuoos.com/EggPlanet/egg_system_rules.git/enum"
zhios_order_relate_logx "code.fnuoos.com/EggPlanet/egg_system_rules.git/utils/logx"
"fmt"
"github.com/gomodule/redigo/redis"
"strings"
@@ -12,6 +14,12 @@ import (
// ImageBucket is 获取域名
func ImageBucket(engine *xorm.Engine, conn redis.Conn) (string, string) {
sysCfgDb := implement.NewSysCfgDb(engine, conn)
defer func(sysCfgDb dao.SysCfgDao) {
err := sysCfgDb.Close()
if err != nil {
zhios_order_relate_logx.Error("redis close err:" + err.Error()) // 记录错误信息
}
}(sysCfgDb)
res := sysCfgDb.SysCfgFindWithDb(enum.AliyunOssBucketScheme, enum.AliyunOssDomain)
return res[enum.AliyunOssBucketScheme], res[enum.AliyunOssDomain]
}


Loading…
Cancel
Save