Checks for boolean values of nil or 0

This change is related to #971 

It only adds the _halt_on_stderr_ param if the value isn't `nil` or `0`.