Add if and return statments. Add if checks back into many ExpectNode<>() checks (makes code a bit less clear but helps guard against errors)