code: function(vertex) {
        if (vertex.prev === null) {
          this.head = vertex.next;
        } else {
          vertex.prev.next = vertex.next;
        }
  
        if (vertex.next === null) {
          this.tail = vertex.prev;
        } else {
          vertex.next.prev = vertex.prev;
        }
  
        return this;
      }
docs: Removes a vertex from the linked list