Added append and prepend to thread.