Update the status when editing