 						}
 						else if (simpleGeomIsLine) // if a line, check for bounds intersect line
 						{
-							if (ComputationalGeometryUtils.polygonOverlapsLine(
-								_tempBoundsPolygon, /* polygon */ 
-								vertices[0].x, vertices[0].y, /* point A on AB */
-								vertices[1].x, vertices[1].y /* point B on AB */ ))
+							if (polygonOverlapsPolyLine(_tempBoundsPolygon, vertices))
 							{
 								result.push(key);
 								continue keyLoop;

			return _kdTree.queryRange(minKDKey, maxKDKey);
		}
		
		/**
		 * This function will get the keys which intersect with the bounds.
		 * 

							}
							else // point
							{
								if (polygonOverlapsPolyPoint(_tempBoundsPolygon, part))
								{
									result.push(key);
									continue keyLoop;
