We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 191c618 commit 68151d9Copy full SHA for 68151d9
docs/database/Redis/Redis.md
@@ -304,7 +304,7 @@ public Object getObjectInclNullById(Integer id) {
304
// 从缓存中获取数据
305
Object cacheValue = cache.get(id);
306
// 缓存为空
307
- if (cacheValue != null) {
+ if (cacheValue == null) {
308
// 从数据库中获取
309
Object storageValue = storage.get(key);
310
// 缓存空对象
@@ -367,4 +367,4 @@ public Object getObjectInclNullById(Integer id) {
367
368
**Java工程师必备学习资源:** 一些Java工程师常用学习资源公众号后台回复关键字 **“1”** 即可免费无套路获取。
369
370
-
+
0 commit comments