Commit d457256
authored
Update Map.ofEntries usage
Looks like each entry should be wrapped in its own `Map.entry(K,V)` before being passed to `Map.ofEntries()`
Change:
From
`Map<String, Integer> temperatures = Map.ofEntries(Map.entry("Mon", 30, "Tue", 28, "Wed", 32));`
To
`Map<String, Integer> temperatures2 = Map.ofEntries(
Map.entry("Mon", 30),
Map.entry("Tue", 28),
Map.entry("Wed", 32)
);`1 parent d8e92d5 commit d457256
1 file changed
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
148 | | - | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
149 | 153 | | |
150 | 154 | | |
151 | 155 | | |
| |||
0 commit comments