Skip to content

Commit

Permalink
Merge branch 'api-bugfix' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
serefyarar committed Feb 6, 2024
2 parents ef18fec + b731e75 commit 2f66d7e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/src/libs/lit/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ export const getPKPSession = async (session, index) => {
throw new Error("Unauthenticated DID");
}

const sessionCacheKey = `${session.did.parent}:${index.signerFunction}`
const sessionCacheKey = `${session.did.parent}:${index.id}:${index.signerFunction}`

const existingSessionStr = await redis.hGet("sessions", sessionCacheKey);

Expand Down Expand Up @@ -184,7 +184,7 @@ export const getPKPSession = async (session, index) => {
return null;
}

if(! resp.signatures.sig1 ){
if(!resp.signatures || !resp.signatures.sig1 ){
throw new Error("No signature returned")
}

Expand Down

0 comments on commit 2f66d7e

Please sign in to comment.