fix to update procedure