Added validation on editing todos