mirror of
https://github.com/Permissionless-Software-Foundation/psf-memo.git
synced 2026-09-21 16:52:01 -07:00
Skip empty room names in topic index backfill
A historical rooms record with an empty room name made the backfill call
put('') and abort with "key cannot be an empty String". Skip records with no
room name so the one-time backfill can complete; such rooms have no listing
entry to write.
By specifier.
This commit is contained in:
@@ -47,6 +47,7 @@ async function collectSummaries (roomsDb) {
|
||||
|
||||
for await (const [key, value] of roomsDb.iterator()) {
|
||||
const room = roomFromEntry(key, value)
|
||||
if (!room) continue
|
||||
if (!summaries.has(room)) {
|
||||
summaries.set(room, { room, postCount: 0, lastHeight: 0 })
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user