fixed getitd write bugs