Skip to content

Commit

Permalink
fix: lookup the collection id from the payload
Browse files Browse the repository at this point in the history
  • Loading branch information
kespinola committed Jun 20, 2023
1 parent 0a69f71 commit 29ddc54
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions consumer/src/events.rs
Original file line number Diff line number Diff line change
Expand Up @@ -442,8 +442,9 @@ impl Processor {
key: SolanaNftEventKey,
payload: MintMetaplexEditionTransaction,
) -> Result<()> {
let id = Uuid::parse_str(&payload.collection_id.clone())?;
let collection = Collection::find_by_id(&self.db, id)
let id = Uuid::parse_str(&key.id.clone())?;
let collection_id = Uuid::parse_str(&payload.collection_id)?;
let collection = Collection::find_by_id(&self.db, collection_id)
.await?
.ok_or(ProcessorError::RecordNotFound)?;

Expand Down

0 comments on commit 29ddc54

Please sign in to comment.