public void removeReaction ( Emoji emoji , boolean you ) { Optional < Reaction > reaction = reactions . stream ( ) . filter ( r -> emoji . equalsEmoji ( r . getEmoji ( ) ) ) . findAny ( ) ; reaction . ifPresent ( r -> ( ( ReactionImpl ) r ) . decrementCount ( you ) ) ; reactions . removeIf ( r -> r . getCount ( ) <= 0 ) ; }
Removes an emoji from the list of reactions .