CHICAGO (CBS) — Voters at one Chicago polling place were surprised to find one of the judges showing his presidential preference this morning.

“That’s against the rules.” Jim Allen, with the Chicago board of election commissioners said.

READ MORE: Shuttered For More Than Five Years, Chippewa Campground At Kankakee River State Park Could Soon See Repairs

The judge was wearing an Obama cap as he handed out ballots to voters at a polling place on Plymouth Court at Roosevelt.

He wasn’t wearing it for long.

READ MORE: Mayor Lori Lightfoot Nominates Annette Nance-Holt As First Black Woman To Serve As City's Fire Commissioner

Allen says as soon as the board got word of it, the judge was told to ditch the cap but was allowed to keep working.

“It’s clearly inappropriate, but it’s not something whether the person (the judge) was denying a person the right to vote.” Allen said.

MORE NEWS: Hard Rock Casino Opening In Gary Friday

LISTEN: WBBM Newsradio’s Regine Schlesinger Reports