Skip to content

Commit

Permalink
chore(contracts):1105 Refactored.
Browse files Browse the repository at this point in the history
  • Loading branch information
ds-mwesener committed Jul 18, 2024
1 parent 7fd8f0e commit 87ef392
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.stream.Collectors;

@Component
@Slf4j
Expand All @@ -51,8 +50,8 @@ public void saveAllContractAgreements(List<String> contractAgreementIds, Contrac
.contractAgreementId(contractAgreementId)
.type(contractType)
.build())
.map(entity -> (ContractAgreementBaseEntity) entity)
.collect(Collectors.toList());
.map(ContractAgreementBaseEntity.class::cast)
.toList();

List<Contract> contracts = fetchEdcContractAgreements(contractAgreementEntities);
List<ContractAgreementNotificationEntity> contractAgreementsUpdated = ContractAgreementNotificationEntity.fromList(contracts, contractType);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ public class ContractViewRepositoryImpl extends ContractRepositoryImplBase imple

private final JpaContractAgreementViewRepository contractAgreementRepository;

public ContractViewRepositoryImpl(EdcContractAgreementService edcContractAgreementService, ObjectMapper objectMapper, EdcContractAgreementService edcContractAgreementService1, JpaContractAgreementViewRepository contractAgreementRepository, ObjectMapper objectMapper1) {
public ContractViewRepositoryImpl(EdcContractAgreementService edcContractAgreementService,
ObjectMapper objectMapper,
JpaContractAgreementViewRepository contractAgreementRepository) {
super(edcContractAgreementService, objectMapper);
this.contractAgreementRepository = contractAgreementRepository;
}
Expand Down

0 comments on commit 87ef392

Please sign in to comment.