Skip to content

Commit ebf1349

Browse files
committed
fix: add bug workaround to identity create
1 parent f8910da commit ebf1349

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

1-Identities-and-Names/identity-register.mjs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,13 @@ try {
2525

2626
console.log('Identity registered!\nIdentity ID:', result.identity.id.toString());
2727
} catch (e) {
28-
console.error('Something went wrong:\n', e.message);
28+
// Known SDK bug: proof verification fails but the identity was created
29+
// Issue: https://github.com/dashpay/platform/issues/3095
30+
// Extract the real identity ID from the error message
31+
const match = e.message?.match(/proof returned identity (\w+) but/);
32+
if (match) {
33+
console.log('Identity registered!\nIdentity ID:', match[1]);
34+
} else {
35+
console.error('Something went wrong:\n', e.message);
36+
}
2937
}

0 commit comments

Comments
 (0)