Skip to content

Conversation

@Bilogweb3
Copy link
Contributor

  1. MergeCoordinator.findValidAncestor():
    Replace .map() + .orElse(Optional.empty()) with .flatMap() to eliminate unnecessary Optional<Optional<>> nesting.

  2. BftBlockCreatorFactory.toVote():
    Remove redundant Optional.of() wrapper inside .map() and unnecessary .orElse(Optional.empty()) call.

Signed-off-by: Bilog WEB3 <155262265+Bilogweb3@users.noreply.github.com>
@macfarla macfarla self-assigned this Nov 19, 2025
Copy link
Contributor

@macfarla macfarla left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is cleaner, thanks

@macfarla macfarla enabled auto-merge (squash) November 20, 2025 00:01
@macfarla macfarla merged commit 41b3816 into hyperledger:main Nov 20, 2025
46 checks passed
pinges pushed a commit to pinges/besu that referenced this pull request Dec 15, 2025
…erledger#9440)

Signed-off-by: Bilog WEB3 <155262265+Bilogweb3@users.noreply.github.com>
Co-authored-by: Sally MacFarlane <macfarla.github@gmail.com>
Signed-off-by: stefan.pingel@consensys.net <stefan.pingel@consensys.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants