From afac00de336762f881da169b12f1c7e9518c8638 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子Li <15040126243@163.com>
Date: 星期日, 13 十一月 2022 22:06:05 +0800
Subject: [PATCH] fix 修复 使用缓冲流 导致上传异常问题 回滚错误提交 #35fac6c

---
 ruoyi-framework/src/main/java/com/ruoyi/framework/satoken/dao/PlusSaTokenDao.java |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/ruoyi-framework/src/main/java/com/ruoyi/framework/satoken/dao/PlusSaTokenDao.java b/ruoyi-framework/src/main/java/com/ruoyi/framework/satoken/dao/PlusSaTokenDao.java
index a08503d..83c3d54 100644
--- a/ruoyi-framework/src/main/java/com/ruoyi/framework/satoken/dao/PlusSaTokenDao.java
+++ b/ruoyi-framework/src/main/java/com/ruoyi/framework/satoken/dao/PlusSaTokenDao.java
@@ -68,7 +68,8 @@
      */
     @Override
     public long getTimeout(String key) {
-        return RedisUtils.getTimeToLive(key) / 1000;
+        long timeout = RedisUtils.getTimeToLive(key);
+        return timeout < 0 ? timeout : timeout / 1000;
     }
 
     /**
@@ -141,7 +142,8 @@
      */
     @Override
     public long getObjectTimeout(String key) {
-        return RedisUtils.getTimeToLive(key) / 1000;
+        long timeout = RedisUtils.getTimeToLive(key);
+        return timeout < 0 ? timeout : timeout / 1000;
     }
 
     /**
@@ -168,10 +170,9 @@
      * 鎼滅储鏁版嵁
      */
     @Override
-    public List<String> searchData(String prefix, String keyword, int start, int size) {
+    public List<String> searchData(String prefix, String keyword, int start, int size, boolean sortType) {
         Collection<String> keys = RedisUtils.keys(prefix + "*" + keyword + "*");
         List<String> list = new ArrayList<>(keys);
-        return SaFoxUtil.searchList(list, start, size);
+        return SaFoxUtil.searchList(list, start, size, sortType);
     }
-
 }

--
Gitblit v1.9.3