scalastyle is complaining about akka send of boolean

195 Views Asked by At

sender ! true

and

sender ! false

are generating "Boolean expression can be simplified" warnings by scalastyle.

How can I make these warnings go away?

1

There are 1 best solutions below

1
On BEST ANSWER

You can disable the SimplifyBooleanExpression checker on the lines where you use ! true or ! false.

sender ! true // scalastyle:ignore simplify.boolean.expression

Or on multiple lines :

// scalastyle:off simplify.boolean.expression
sender ! false
// scalastyle:on simplify.boolean.expression