Being robust to null inputs