X-Git-Url: https://git.saurik.com/redis.git/blobdiff_plain/5290f05c34291ab6853ad097893238efb53bfb8e..813ed29248b236b4a20cfac4e66a30e6c0390deb:/src/db.c diff --git a/src/db.c b/src/db.c index ad6e7114..536dc6d8 100644 --- a/src/db.c +++ b/src/db.c @@ -127,7 +127,11 @@ void setKey(redisDb *db, robj *key, robj *val) { } int dbExists(redisDb *db, robj *key) { - return dictFind(db->dict,key->ptr) != NULL; + if (dictFind(db->dict,key->ptr) != NULL) + return 1; + if (recover(db, key) != NULL) + return 1; + return 0; } /* Return a random key, in form of a Redis object.