I know this code is probably copied from the old page and not your doing, but this should be `next unless defined`.