正在显示
1 个修改的文件
包含
2 行增加
和
2 行删除
| @@ -68,12 +68,12 @@ public class RedisConfig extends CachingConfigurerSupport | @@ -68,12 +68,12 @@ public class RedisConfig extends CachingConfigurerSupport | ||
| 68 | "local time = tonumber(ARGV[2])\n" + | 68 | "local time = tonumber(ARGV[2])\n" + |
| 69 | "local current = redis.call('get', key);\n" + | 69 | "local current = redis.call('get', key);\n" + |
| 70 | "if current and tonumber(current) > count then\n" + | 70 | "if current and tonumber(current) > count then\n" + |
| 71 | - " return current;\n" + | 71 | + " return tonumber(current);\n" + |
| 72 | "end\n" + | 72 | "end\n" + |
| 73 | "current = redis.call('incr', key)\n" + | 73 | "current = redis.call('incr', key)\n" + |
| 74 | "if tonumber(current) == 1 then\n" + | 74 | "if tonumber(current) == 1 then\n" + |
| 75 | " redis.call('expire', key, time)\n" + | 75 | " redis.call('expire', key, time)\n" + |
| 76 | "end\n" + | 76 | "end\n" + |
| 77 | - "return current;"; | 77 | + "return tonumber(current);"; |
| 78 | } | 78 | } |
| 79 | } | 79 | } |
-
请 注册 或 登录 后发表评论