File tree Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Original file line number Diff line number Diff line change @@ -174,18 +174,14 @@ private List<BadImage> readTestOutputFile() throws IOException {
174174 Path filePath = FileSystems .getDefault ()
175175 .getPath (OUTPUT_PATH );
176176 if (Files .exists (filePath )) {
177- return Files .lines (filePath )
178- .map (line -> {
179- try {
180- return new ObjectMapper ().readValue (line , BadImage .class );
181- } catch (JsonProcessingException e ) {
182- throw new RuntimeException (e );
183- }
184- })
185- .toList ();
186- } else {
187- return Collections .emptyList ();
188- }
177+ try {
178+ return new ObjectMapper ().readValue (Files .lines (filePath ), BadImage [].class );
179+ } catch (JsonProcessingException e ) {
180+ throw new RuntimeException (e );
181+ }
182+ } else {
183+ return Collections .emptyList ();
184+ }
189185 }
190186
191187 public static void main (String ... args ) {
You can’t perform that action at this time.
0 commit comments