app/controllers/DestinationsController.java
private void createChangeRequest(Integer profileId, Integer destinationId, List<Integer> toAdd, List<Integer> toRemove) {
        DestinationRequest destinationRequest = new DestinationRequest(destinationId, profileId);
        destinationRepository.createDestinationTravellerTypeChangeRequest(destinationRequest).thenApplyAsync(requestId -> {
            if (!toAdd.isEmpty()) {
                destinationRepository.travellerTypeChangesTransaction(requestId, 1, toAdd);
            }
            if (!toRemove.isEmpty()) {
                destinationRepository.travellerTypeChangesTransaction(requestId, 0, toRemove);
            }
            return null;
        });
    }
/**
     * Method to create the requests for changing destination traveller types once user has selected the changes \
     * they wish to make.
     *
     * @param profileId     id of the profile who is requesting the change
     * @param destinationId id of the destination which the user is trying to change
     * @param toAdd         list of traveller types the user wishes to add
     * @param toRemove      list of traveller type the user wishes to delete
     */
Method to create the requests for changing destination traveller types once user has selected the changes \
they wish to make.

@param profileId     id of the profile who is requesting the change
@param destinationId id of the destination which the user is trying to change
@param toAdd         list of traveller types the user wishes to add
@param toRemove      list of traveller type the user wishes to delete
Method to create the requests for changing destination traveller types once user has selected the changes \ they wish to make . @param profileId id of the profile who is requesting the change @param destinationId id of the destination which the user is trying to change @param toAdd list of traveller types the user wishes to add @param toRemove list of traveller type the user wishes to delete
private void createChangeRequest(Integer profileId, Integer destinationId, List<Integer> toAdd, List<Integer> toRemove) {
        DestinationRequest destinationRequest = new DestinationRequest(destinationId, profileId);
        destinationRepository.createDestinationTravellerTypeChangeRequest(destinationRequest).thenApplyAsync(requestId -> {
            if (!toAdd.isEmpty()) {
                destinationRepository.travellerTypeChangesTransaction(requestId, 1, toAdd);
            }
            if (!toRemove.isEmpty()) {
                destinationRepository.travellerTypeChangesTransaction(requestId, 0, toRemove);
            }
            return null;
        });
    }
private void createChangeRequest ( Integer profileId , Integer destinationId , List < Integer > toAdd , List < Integer > toRemove ) { DestinationRequest destinationRequest = new DestinationRequest ( destinationId , profileId ) ; destinationRepository . createDestinationTravellerTypeChangeRequest ( destinationRequest ) . thenApplyAsync ( requestId -> { if ( ! toAdd . isEmpty ( ) ) { destinationRepository . travellerTypeChangesTransaction ( requestId , 1 , toAdd ) ; } if ( ! toRemove . isEmpty ( ) ) { destinationRepository . travellerTypeChangesTransaction ( requestId , 0 , toRemove ) ; } return null ; } ) ; }
Method to create the requests for changing destination traveller types once user has selected the changes \
 they wish to make.
Method to create the requests for changing destination traveller types once user has selected the changes \ they wish to make .