mirror of
https://github.com/Snailclimb/JavaGuide
synced 2025-06-20 22:17:09 +08:00
Fix wrong if statement in Redis.md
This commit is contained in:
parent
191c618593
commit
68151d9503
@ -304,7 +304,7 @@ public Object getObjectInclNullById(Integer id) {
|
||||
// 从缓存中获取数据
|
||||
Object cacheValue = cache.get(id);
|
||||
// 缓存为空
|
||||
if (cacheValue != null) {
|
||||
if (cacheValue == null) {
|
||||
// 从数据库中获取
|
||||
Object storageValue = storage.get(key);
|
||||
// 缓存空对象
|
||||
|
Loading…
x
Reference in New Issue
Block a user