Authorities say a Florida man impersonating an officer flipped the red and blue lights on his SUV while unknowingly trying to stop a car with a real officer.

WFLA reports 26-year-old Matthew Erris was arrested on a charge of impersonating a public officer.

An arrest report says Erris turned on the red and blue lights on his SUV in Plant City, Florida, to try to stop the car in front of him.

The driver was an undercover Hillsborough County sheriff's detective in an unmarked car. He didn't pull over. Instead he called dispatchers to alert other deputies, who later stopped Erris.

Erris admitted he installed the lights and used them to get through heavy traffic.

Jail records did not list an attorney for Erris.