improve logic for custom delims to ensure that defaults are used when undefined values are passed