Be smarter about paths