The Minnesota Supreme Court on Wednesday upheld a law signed last year by Governor Tim Walz, the Democratic vice presidential candidate, that restores the right to vote for felons who have completed their prison terms.