Use method reference instead of lambda

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=239633243
This commit is contained in:
mcilwain 2019-03-21 11:14:37 -07:00 committed by jianglai
parent 32c0eee5b9
commit 2481704d00

View file

@ -502,9 +502,7 @@ public class RegistrarSettingsAction implements Runnable, JsonActionRunner.JsonA
sendEmailUtils.sendEmail(
String.format(
"Registrar %s (%s) updated in %s",
existingRegistrar.getRegistrarName(),
existingRegistrar.getClientId(),
environment),
existingRegistrar.getRegistrarName(), existingRegistrar.getClientId(), environment),
String.format(
"The following changes were made on %s to the registrar %s by %s:\n\n%s",
environment,
@ -512,10 +510,7 @@ public class RegistrarSettingsAction implements Runnable, JsonActionRunner.JsonA
authResult.userIdForLogging(),
DiffUtils.prettyPrintDiffedMap(diffs, null)),
existingContacts.stream()
.map(
contact -> {
return contact.getEmailAddress();
})
.map(RegistrarContact::getEmailAddress)
.collect(toImmutableList()));
}