Skip to content

Commit

Permalink
fix: Load databases by orbitdb address.
Browse files Browse the repository at this point in the history
  • Loading branch information
haydenyoung committed Jul 16, 2024
1 parent 82bfe59 commit f117b26
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib/orbiter.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@ export default async ({ orbitdb, defaultAccess, verbose } = {}) => {
await orbitdb.ipfs.libp2p.handle(voyagerProtocol, handleMessages)

for await (const db of pins.iterator()) {
dbs[db.value] = await orbitdb.open(db.value)
log('db opened', db.value)
dbs[db.key] = await orbitdb.open(db.key)
log('db opened', db.key)
}

log(dbs.length, 'dbs loaded')
log(Object.keys(dbs).length, 'dbs loaded')

const stop = async () => {
await orbitdb.ipfs.libp2p.unhandle(voyagerProtocol)
Expand Down

0 comments on commit f117b26

Please sign in to comment.