Skip to content

Commit

Permalink
re ordger did validation steps
Browse files Browse the repository at this point in the history
Signed-off-by: PatStLouis <[email protected]>
  • Loading branch information
PatStLouis committed Sep 27, 2024
1 parent a4e4eed commit d850f8f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions aries_cloudagent/wallet/askar.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,10 @@ async def create_local_did(
verkey_bytes = keypair.get_public_bytes()
verkey = bytes_to_b58(verkey_bytes)

did = did_validation.validate_or_derive_did(
method, key_type, verkey_bytes, did
)

try:
await self._session.handle.insert_key(
verkey, keypair, metadata=json.dumps(metadata)
Expand All @@ -269,10 +273,6 @@ async def create_local_did(
else:
raise WalletError("Error inserting key") from err

did = did_validation.validate_or_derive_did(
method, key_type, verkey_bytes, did
)

item = await self._session.handle.fetch(CATEGORY_DID, did, for_update=True)
if item:
did_info = item.value_json
Expand Down

0 comments on commit d850f8f

Please sign in to comment.