Fix linkedlist refactor