Refactor links using path helper functions