Fixed Writing data (markDirty())