Remove unnecessary null check.