Fix for `is True` and `is None` instead of `==`
Merge pull request #3778 from basepi/isnonefix

Fix for `is True` and `is None` instead of `==`