reverted path comparison improvement

fixes https://github.com/nodeca/hike-js/issues/11
added a flag to stop searching on first found path

fixes https://github.com/nodeca/hike-js/issues/10