mobiletto 1.1.21 → 1.1.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/util/redis.js +10 -4
package/package.json
CHANGED
package/util/redis.js
CHANGED
|
@@ -131,10 +131,16 @@ class MobilettoCache {
|
|
|
131
131
|
return await new Promise((resolve, reject) => {
|
|
132
132
|
this.scanner.eachScan(pattern, {}, async (matchingKeys) => {
|
|
133
133
|
for (const key of matchingKeys) {
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
134
|
+
asyncFunc(key).then(
|
|
135
|
+
(val) => {
|
|
136
|
+
if (typeof val !== 'undefined') {
|
|
137
|
+
results.push(val)
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
(e) => {
|
|
141
|
+
logger.error(`applyToMatchingKeys: error with key ${key}: ${e}`)
|
|
142
|
+
reject(e)
|
|
143
|
+
})
|
|
138
144
|
}
|
|
139
145
|
}, (err, matchCount) => {
|
|
140
146
|
if (err) reject(err)
|