See this code:
somePostRequest
.bodyToMono(String.class)
.flatMap(token -> Mono.just(addTokenToMap(token,bankCode)));
Problem here is that the method: addTokenToMap()
- needs to be wrapped in try catch block - which I am looking to avoid. Is there a way to handle this with perhaps doOnError()
or something similar?