Updating map method

This commit is contained in:
Niket Agrawal 2023-11-08 22:44:29 +05:30
parent c7bd43e881
commit ab70c92934
1 changed files with 1 additions and 1 deletions

View File

@ -25,7 +25,7 @@ public class FirstMatchingElementUnitTest {
counter.getAndIncrement();
return searchName.equals(user.getUserName());
})
.map(user -> counter.get())
.mapToInt(user -> counter.get())
.findFirst()
.orElse(-1);