handle errors when submitting moves