Fixed the object declaration for LinkedList