Skip to content

Commit

Permalink
[Fix] Fix accidental DTO usage when removing vocabulary.
Browse files Browse the repository at this point in the history
  • Loading branch information
ledsoft committed Aug 5, 2024
1 parent 13e146f commit b0edc7b
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -282,8 +282,9 @@ public void runTextAnalysisOnAllVocabularies() {
@Transactional
@PreAuthorize("@vocabularyAuthorizationService.canRemove(#asset)")
public void remove(Vocabulary asset) {
aclService.findFor(asset).ifPresent(aclService::remove);
repositoryService.remove(asset);
Vocabulary toRemove = repositoryService.findRequired(asset.getUri());
aclService.findFor(toRemove).ifPresent(aclService::remove);
repositoryService.remove(toRemove);
}

/**
Expand Down

0 comments on commit b0edc7b

Please sign in to comment.