Skip to content

Commit

Permalink
Merge pull request #427 from desci-labs/check-submission-status
Browse files Browse the repository at this point in the history
Return early if submission has been processed successfully before
  • Loading branch information
shadrach-tayo authored Jul 15, 2024
2 parents 4c3efae + 0d8bdd4 commit 713f34b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions desci-server/src/controllers/doi/mint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@ export const handleCrossrefNotificationCallback = async (
return;
}

if (submission.status === DoiStatus.SUCCESS) {
new SuccessMessageResponse().send(res);
return;
}

await doiService.updateSubmission({ id: submission.id }, { notification: req.payload });
logger.info('SUBMISSION UPDATED');

Expand Down

0 comments on commit 713f34b

Please sign in to comment.