Fix url histroy write; Fix redundant downloaded thumbnails.