@0xpolygonid/js-sdk 1.29.0 → 1.29.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -82231,7 +82231,7 @@ var PolygonIdSdk = (function (exports) {
82231
82231
  // group requests by query group id
82232
82232
  for (const proofRequest of requestScope) {
82233
82233
  const groupId = proofRequest.query.groupId;
82234
- const proofResp = responseScope.find((resp) => resp.id === proofRequest.id);
82234
+ const proofResp = responseScope.find((resp) => resp.id.toString() === proofRequest.id.toString());
82235
82235
  if (!proofResp) {
82236
82236
  throw new Error(`proof is not given for requestId ${proofRequest.id}`);
82237
82237
  }
@@ -84014,6 +84014,7 @@ var PolygonIdSdk = (function (exports) {
84014
84014
  return circuitInputs.inputsMarshal();
84015
84015
  };
84016
84016
  this.credentialAtomicQueryV3OnChainPrepareInputs = async ({ preparedCredential, identifier, proofReq, params, circuitQueries }) => {
84017
+ const id = Q$2.idFromDID(identifier);
84017
84018
  const circuitClaimData = await this.newCircuitClaimData(preparedCredential);
84018
84019
  circuitClaimData.nonRevProof = toClaimNonRevStatus(preparedCredential.revStatus);
84019
84020
  let proofType;
@@ -84063,20 +84064,17 @@ var PolygonIdSdk = (function (exports) {
84063
84064
  const isEthIdentity = isEthereumIdentity(identifier);
84064
84065
  circuitInputs.isBJJAuthEnabled = isEthIdentity ? 0 : 1;
84065
84066
  circuitInputs.challenge = BigInt(params.challenge ?? 0);
84066
- const { nonce: authProfileNonce, genesisDID } = await this._identityWallet.getGenesisDIDMetadata(identifier);
84067
- const id = Q$2.idFromDID(genesisDID);
84068
84067
  const stateProof = await this._stateStorage.getGISTProof(id.bigInt());
84069
84068
  const gistProof = toGISTProof(stateProof);
84070
84069
  circuitInputs.gistProof = gistProof;
84071
84070
  // auth inputs
84072
84071
  if (circuitInputs.isBJJAuthEnabled === 1) {
84073
- const authPrepared = await this.prepareAuthBJJCredential(genesisDID);
84072
+ const authPrepared = await this.prepareAuthBJJCredential(identifier);
84074
84073
  const authClaimData = await this.newCircuitClaimData({
84075
84074
  credential: authPrepared.credential,
84076
84075
  credentialCoreClaim: authPrepared.coreClaim
84077
84076
  });
84078
84077
  const signature = await this._identityWallet.signChallenge(circuitInputs.challenge, authPrepared.credential);
84079
- circuitInputs.profileNonce = BigInt(authProfileNonce);
84080
84078
  circuitInputs.authClaim = authClaimData.claim;
84081
84079
  circuitInputs.authClaimIncMtp = authClaimData.proof;
84082
84080
  circuitInputs.authClaimNonRevMtp = authPrepared.nonRevProof.proof;