master
huanghai 5 years ago
parent 75f8ebd19d
commit 783d397ad5

@ -4,6 +4,7 @@ import (
"dsBaseRpc/Const/ErrorConst"
"dsBaseRpc/Utils/ConfigUtil"
"dsBaseRpc/Utils/LogUtil"
"fmt"
"github.com/go-redis/redis/v7"
"time"
)
@ -61,7 +62,10 @@ func SET(key string, value string, ttl time.Duration) {
*/
func IncrBy(key string, value int64) int64 {
c, _ := RedisClient.IncrBy(key, value).Result()
c, err := RedisClient.IncrBy(key, value).Result()
if err!=nil{
fmt.Println(err.Error())
}
return c
}

Loading…
Cancel
Save