Skip to content

Commit

Permalink
feat: Implement delete news article service layer - EXO-70383 - Meeds…
Browse files Browse the repository at this point in the history
…io/MIPs#119 (#22)
  • Loading branch information
sofyenne committed Apr 22, 2024
1 parent b5f9646 commit 75be862
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,8 @@ public void deleteNews(String newsId, Identity currentIdentity, boolean isDraft)
deleteDraftArticle(newsId, currentIdentity.getUserId(), true);
} else {
deleteArticle(news, currentIdentity);
MetadataObject newsMetadataObject = new MetadataObject(NewsUtils.NEWS_METADATA_OBJECT_TYPE, newsId);
metadataService.deleteMetadataItemsByObject(newsMetadataObject);
indexingService.unindex(NewsIndexingServiceConnector.TYPE, String.valueOf(news.getId()));
NewsUtils.broadcastEvent(NewsUtils.DELETE_NEWS, currentIdentity.getUserId(), news);
}
Expand Down

0 comments on commit 75be862

Please sign in to comment.