Polyline 

Lines are been draw... simple plain implementation
Checking here makes sense, it's hard to do it further upstream in a really general way. In this case we know it's invalid to make polygons from a one-point-line, but if you're symbolizing 'line' geometry as a sequence of points then why not allow it?