guard against nil before checking number of lines in address