dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #40286
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20402: minor cleanup
------------------------------------------------------------
revno: 20402
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2015-09-30 11:06:58 +0700
message:
minor cleanup
modified:
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/trackedentity/DefaultTrackedEntityInstanceService.java
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/trackedentity/DefaultTrackedEntityInstanceService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/trackedentity/DefaultTrackedEntityInstanceService.java 2015-09-30 04:01:49 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/trackedentity/DefaultTrackedEntityInstanceService.java 2015-09-30 04:06:58 +0000
@@ -611,20 +611,9 @@
{
trackedEntityInstanceStore.update( instance );
- for ( TrackedEntityAttributeValue av : valuesForSave )
- {
- attributeValueService.addTrackedEntityAttributeValue( av );
- }
-
- for ( TrackedEntityAttributeValue av : valuesForUpdate )
- {
- attributeValueService.updateTrackedEntityAttributeValue( av );
- }
-
- for ( TrackedEntityAttributeValue av : valuesForDelete )
- {
- attributeValueService.deleteTrackedEntityAttributeValue( av );
- }
+ valuesForSave.forEach( attributeValueService::addTrackedEntityAttributeValue );
+ valuesForUpdate.forEach( attributeValueService::updateTrackedEntityAttributeValue );
+ valuesForDelete.forEach( attributeValueService::deleteTrackedEntityAttributeValue );
if ( shouldSaveRepresentativeInformation( instance, representativeId ) )
{