Spaces:
Running
Running
Update app.js
Browse files
app.js
CHANGED
|
@@ -23,10 +23,12 @@ const drive = google.drive({ version: 'v3', auth });
|
|
| 23 |
|
| 24 |
async function getAllRedisData() {
|
| 25 |
const result = [];
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
|
|
|
|
|
|
| 30 |
return result;
|
| 31 |
}
|
| 32 |
|
|
|
|
| 23 |
|
| 24 |
async function getAllRedisData() {
|
| 25 |
const result = [];
|
| 26 |
+
const keys = await redis.keys('*'); // '*' matches all keys
|
| 27 |
+
keys.forEach(key => {
|
| 28 |
+
const value = await redis.get(key);
|
| 29 |
+
result.push({ key, value }); // Preserve both key and value
|
| 30 |
+
});
|
| 31 |
+
|
| 32 |
return result;
|
| 33 |
}
|
| 34 |
|