fix bug in pathIntersection() (maybe)