@@ -3132,10 +3132,9 @@ public final Flux<T> expand(Function<? super T, ? extends Publisher<? extends T>
31323132 * @return a filtered {@link Mono}
31333133 */
31343134 public final Mono <T > filter (final Predicate <? super T > tester ) {
3135- if (this instanceof Fuseable ) {
3136- return onAssembly (new MonoFilterFuseable <>(this , tester ));
3137- }
3138- return onAssembly (new MonoFilter <>(this , tester ));
3135+ return onAssembly (this instanceof Fuseable
3136+ ? new MonoFilterFuseable <>(this , tester )
3137+ : new MonoFilter <>(this , tester ));
31393138 }
31403139
31413140 /**
@@ -3291,10 +3290,9 @@ public final Mono<Boolean> hasElement() {
32913290 * @return a transformed {@link Mono}
32923291 */
32933292 public final <R > Mono <R > handle (BiConsumer <? super T , SynchronousSink <R >> handler ) {
3294- if (this instanceof Fuseable ) {
3295- return onAssembly (new MonoHandleFuseable <>(this , handler ));
3296- }
3297- return onAssembly (new MonoHandle <>(this , handler ));
3293+ return (this instanceof Fuseable )
3294+ ? onAssembly (new MonoHandleFuseable <>(this , handler ))
3295+ : onAssembly (new MonoHandle <>(this , handler ));
32983296 }
32993297
33003298 /**
@@ -3418,10 +3416,9 @@ public final Mono<T> log(@Nullable String category,
34183416 SignalLogger <T > log = new SignalLogger <>(this , category , level ,
34193417 showOperatorLine , options );
34203418
3421- if (this instanceof Fuseable ) {
3422- return onAssembly (new MonoLogFuseable <>(this , log ));
3423- }
3424- return onAssembly (new MonoLog <>(this , log ));
3419+ return (this instanceof Fuseable )
3420+ ? onAssembly (new MonoLogFuseable <>(this , log ))
3421+ : onAssembly (new MonoLog <>(this , log ));
34253422 }
34263423
34273424
@@ -3468,10 +3465,9 @@ public final Mono<T> log(Logger logger,
34683465 s -> logger ,
34693466 options );
34703467
3471- if (this instanceof Fuseable ) {
3472- return onAssembly (new MonoLogFuseable <>(this , log ));
3473- }
3474- return onAssembly (new MonoLog <>(this , log ));
3468+ return (this instanceof Fuseable )
3469+ ? onAssembly (new MonoLogFuseable <>(this , log ))
3470+ : onAssembly (new MonoLog <>(this , log ));
34753471 }
34763472
34773473 /**
@@ -3486,10 +3482,9 @@ public final Mono<T> log(Logger logger,
34863482 * @return a new {@link Mono}
34873483 */
34883484 public final <R > Mono <R > map (Function <? super T , ? extends R > mapper ) {
3489- if (this instanceof Fuseable ) {
3490- return onAssembly (new MonoMapFuseable <>(this , mapper ));
3491- }
3492- return onAssembly (new MonoMap <>(this , mapper ));
3485+ return (this instanceof Fuseable )
3486+ ? onAssembly (new MonoMapFuseable <>(this , mapper ))
3487+ : onAssembly (new MonoMap <>(this , mapper ));
34933488 }
34943489
34953490 /**
@@ -3574,11 +3569,10 @@ public final Mono<T> metrics() {
35743569 if (!Metrics .isInstrumentationAvailable ()) {
35753570 return this ;
35763571 }
3577-
3578- if (this instanceof Fuseable ) {
3579- return onAssembly (new MonoMetricsFuseable <>(this ));
3580- }
3581- return onAssembly (new MonoMetrics <>(this ));
3572+
3573+ return (this instanceof Fuseable )
3574+ ? onAssembly (new MonoMetricsFuseable <>(this ))
3575+ : onAssembly (new MonoMetrics <>(this ));
35823576 }
35833577
35843578 /**
0 commit comments