|
|
@@ -8,6 +8,7 @@ package user |
|
|
import ( |
|
|
import ( |
|
|
"errors" |
|
|
"errors" |
|
|
"fmt" |
|
|
"fmt" |
|
|
|
|
|
"github.com/gomodule/redigo/redis" |
|
|
"net/http" |
|
|
"net/http" |
|
|
"strings" |
|
|
"strings" |
|
|
|
|
|
|
|
|
@@ -1845,7 +1846,7 @@ func SendVerifyCode(ctx *context.Context, slideImage *slideimage.SlideImage, for |
|
|
defer redisConn.Close() |
|
|
defer redisConn.Close() |
|
|
|
|
|
|
|
|
sendTimes, err := phoneService.GetPhoneNumberSendTimes(redisConn, phoneNumber) |
|
|
sendTimes, err := phoneService.GetPhoneNumberSendTimes(redisConn, phoneNumber) |
|
|
if err != nil { |
|
|
|
|
|
|
|
|
if err != nil && err!=redis.ErrNil { |
|
|
log.Warn("redis err", err) |
|
|
log.Warn("redis err", err) |
|
|
ctx.JSON(http.StatusOK, models.BaseErrorMessage(ctx.Tr("phone.query_err"))) |
|
|
ctx.JSON(http.StatusOK, models.BaseErrorMessage(ctx.Tr("phone.query_err"))) |
|
|
return |
|
|
return |
|
|
|