update reset attach file and comment, format code