Simplify tests for null in helper