Skip to content

Commit

Permalink
Fixed verifyDb when db empty
Browse files Browse the repository at this point in the history
  • Loading branch information
macterra committed Mar 18, 2024
1 parent ba43f39 commit 3ff3698
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions gatekeeper.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ export function writeDb(db) {

export async function verifyDb() {
const db = loadDb();

if (!db.anchors) {
return 0;
}

const dids = Object.keys(db.anchors);
let n = 0;
let invalid = 0;
Expand Down

0 comments on commit 3ff3698

Please sign in to comment.