Former University of Colorado Law Dean Phil Weiser has secured the Democratic nomination for Colorado attorney general in a nail-biter of a primary.

The vote was so close that Weiser’s opponent, state Rep. Joe Salazar, did not concede to Weiser until June 30—five days after the primary. Weiser, who remains on the law faculty, secured 50.43 percent of the vote against Salazar’s 49.57. A mere 5,000 votes separated the two candidates, with 590,000 cast across the state.