Cleaned up route learning