Skip to content

Commit

Permalink
Merge pull request DSpace#9890 from atmire/w2p-118774_fix-doi-deletio…
Browse files Browse the repository at this point in the history
…n-bug

Status of DOI object should be set to TO_BE_DELETED when the related item is removed
  • Loading branch information
tdonohue authored Nov 11, 2024
2 parents 25d6b50 + 352f4c2 commit 12c36da
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
import org.dspace.harvest.HarvestedItem;
import org.dspace.harvest.service.HarvestedItemService;
import org.dspace.identifier.DOI;
import org.dspace.identifier.DOIIdentifierProvider;
import org.dspace.identifier.IdentifierException;
import org.dspace.identifier.service.DOIService;
import org.dspace.identifier.service.IdentifierService;
Expand Down Expand Up @@ -851,6 +852,7 @@ protected void rawDelete(Context context, Item item) throws AuthorizeException,
DOI doi = doiService.findDOIByDSpaceObject(context, item);
if (doi != null) {
doi.setDSpaceObject(null);
doi.setStatus(DOIIdentifierProvider.TO_BE_DELETED);
}

// remove version attached to the item
Expand Down

0 comments on commit 12c36da

Please sign in to comment.