DETROIT (AP) — A former official at the United Auto Workers was sentenced Tuesday to nearly five years in prison for embezzling $2.1 million.

Timothy Edmunds was secretary-treasurer of UAW Local 412, which represents about 2,600 people who work for Stellantis, formerly known as Fiat Chrysler, at factories in the Detroit area.

READ MORE: 5-Year-Old Injured In Eastpointe Accidental Shooting; Gun Safety Instructor Says Lock Up Your Guns

Edmunds used the union’s credit cards for personal purchases. He also cashed checks and transferred money into his accounts, investigators said.

“Mr. Edmunds betrayed his union brothers and sisters by stealing their dues money to satisfy his own greed,” U.S. Attorney Dawn Ison said.

READ MORE: Ballot Initiative To Strike Detroit's Adult-Use Ordinance Rejected, Opponents Continue To Fight

Edmunds gambled and spent money on guns, cars and child-support payments. He pleaded guilty in March to embezzlement and money laundering.

“These offenses stemmed from his drug and gambling addiction,” defense attorney Joseph Arnone said in a court filing.

MORE NEWS: 5-Year-Old Accidentally Shoots Self In Foot At Eastpointe Home

The UAW says its auditors discovered the theft, and the findings were shared with federal authorities.