I am new to Reactive programming, so can use some help. I have below code where I am not liking two different methods for error handling. I want to combine them in one method. What is the correct approach?
mono.doOnError(error -> logError(error))
.onErrorMap(
t -> !(t instanceof DatabaseException),
t -> DatabaseExceptionMapper.mapException(t));