support line and polygon
Rubocop style fixes