Closed
Description
This results in this error when using preHandler in a ComponentFlow using the builder:
java.lang.NullPointerException: Cannot invoke "org.springframework.shell.component.flow.SingleItemSelectorSpec.next(java.util.function.Function)" because the return value of "org.springframework.shell.component.flow.SingleItemSelectorSpec.preHandler(java.util.function.Consumer)" is null
Looks like a typo to me:
@Override public SingleItemSelectorSpec preHandler(Consumer<SingleItemSelectorContext<String, SelectorItem<String>>> handler) { this.preHandlers.add(handler); return null; }