Skip to content

Commit

Permalink
Fix:命中缓存返回错误
Browse files Browse the repository at this point in the history
  • Loading branch information
CareyWang committed Feb 12, 2020
1 parent 12bfe87 commit 075c2a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func main() {
if 1 == *cache {
_shortUrl, err := redisClient.Get(longUrl).Result()
if err == nil && _shortUrl != "" {
res.LongUrl = _shortUrl
res.ShortUrl = _shortUrl
c.JSON(200, res)
return
}
Expand Down

0 comments on commit 075c2a9

Please sign in to comment.