Fixed typo in mass write method