Skip to content

Commit acfbe02

Browse files
Polish
1 parent 5beaae6 commit acfbe02

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

spring-core/src/main/java/org/springframework/util/MultiToSingleValueMapAdapter.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,11 +139,11 @@ public Collection<V> values() {
139139
Collection<V> values = this.values;
140140
if (values == null) {
141141
Collection<List<V>> targetValues = this.targetMap.values();
142-
values = new AbstractCollection<V>() {
142+
values = new AbstractCollection<>() {
143143
@Override
144144
public Iterator<V> iterator() {
145145
Iterator<List<V>> targetIterator = targetValues.iterator();
146-
return new Iterator<V>() {
146+
return new Iterator<>() {
147147
@Override
148148
public boolean hasNext() {
149149
return targetIterator.hasNext();

spring-test/src/main/java/org/springframework/test/web/servlet/result/PrintingResultHandler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ protected void printResolvedException(@Nullable Exception resolvedException) thr
207207
protected void printModelAndView(@Nullable ModelAndView mav) throws Exception {
208208
this.printer.printValue("View name", (mav != null) ? mav.getViewName() : null);
209209
this.printer.printValue("View", (mav != null) ? mav.getView() : null);
210-
if (mav == null || mav.getModel().size() == 0) {
210+
if (mav == null || mav.getModel().isEmpty()) {
211211
this.printer.printValue("Model", null);
212212
}
213213
else {

0 commit comments

Comments
 (0)