check for null input