Refactor link code.
Order is first -> next -> next -> last and last -> prev -> prev -> first. Clean it up.
Cleanup routes a bit.