update linked list