Skip to content

Commit

Permalink
Changed attestorOrganiosation ID
Browse files Browse the repository at this point in the history
  • Loading branch information
aminlatifi committed Jun 6, 2024
1 parent 9a4c819 commit 77ce63e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/controllers/authorizeAttestation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@ export const handleAuthorize = async (
recipient,
} = EASContract.events.Attested.decode(log);

const organisationId = schemaUid.toLocaleLowerCase();
const organisation = await ctx.store.findOneBy(Organisation, {
id: schemaUid.toLocaleLowerCase(),
id: organisationId,
issuer: issuer.toLocaleLowerCase(),
});

Expand All @@ -33,7 +34,7 @@ export const handleAuthorize = async (

const attestor = await getAttestor(ctx, accountAddress);

const key = uid.toLocaleLowerCase();
const key = `${organisationId}-${accountAddress}`;

let attestorOrganisation: AttestorOrganisation = new AttestorOrganisation({
id: key,
Expand Down

0 comments on commit 77ce63e

Please sign in to comment.