Whenever I call a method that has too many arguments and the line exceeds the margin, I need it to put each of the params on separate lines.
Original code:
return getSubscriptionList(contractNumber, objects, acceptLanguage, userNumber, bankSystem, groupIdentification).stream()
.map(subscription -> createSubscriptionListItem(subscription,accountsFilterItems))
.collect(Collectors.toList());
After reformatting (this changes it exactly to what I want):
return getSubscriptionList(
contractNumber,
objects,
acceptLanguage,
userNumber,
bankSystem,
groupIdentification
).stream()
.map(subscription -> createSubscriptionListItem(subscription, accountsFilterItems))
.collect(Collectors.toList());
After reformatting the already reformatted code again:
return getSubscriptionList(contractNumber,
objects,
acceptLanguage,
userNumber,
bankSystem,
groupIdentification
).stream()
.map(subscription -> createSubscriptionListItem(subscription, accountsFilterItems))
.collect(Collectors.toList());
Why does it change the format the second time, and how can I change my settings to fix it?