Fixed bug that did not allow teacher to update existing XY