code review points

This commit is contained in:
leif stawnyczy 2024-11-21 13:29:55 -05:00
parent 52657b60bf
commit c043afe1ee
2 changed files with 2 additions and 2 deletions

View File

@ -4,5 +4,5 @@ issue: 6478
jira: SMILE-8955
title: "Transactions with multiple saved search urls will have the saved search urls
deleted in a batch, instead of 1 at a time.
This is a minor performance update
This is a minor performance update.
"

View File

@ -200,7 +200,7 @@ public class TransactionProcessor extends BaseTransactionProcessor {
@SuppressWarnings("rawtypes")
protected void postTransactionProcess(TransactionDetails theTransactionDetails) {
Set<IResourcePersistentId> resourceIds = theTransactionDetails.getUpdatedResourceIds();
if (!resourceIds.isEmpty()) {
if (resourceIds != null && !resourceIds.isEmpty()) {
List<Long> ids = resourceIds.stream().map(r -> (Long) r.getId()).collect(Collectors.toList());
myResourceSearchUrlSvc.deleteByResIds(ids);