This officer’s plan to sabotage his boss wound up backfiring in a major way.

Jal, New Mexico police chief Larry Burns was caught on camera — on two different occasions — having sex in and around a city ambulance.

Image source: screengrab via WHAT

Police chief Larry Burns, recorded by a hidden camera having sex in a city ambulance. (Image source: screengrab via KRQE-TV)

But while his actions were inappropriate, and got him suspended for two weeks, the chief is keeping his job and the officer who planted the camera is getting canned.

Sgt. Joshua Terrell apparently had bad blood with the chief, KRQE-TV reported, and planted the hidden camera in an attempt to sabotage Burns.

The plan paid off, since Burns was caught in a compromising position, but Terrell violated several city policies by sneaking into the garage and planting the camera — and once he had the footage, he released it to the public instead of merely reporting it to the city manager.

“To try to destroy a person that he did not like, I thought we didn’t need (Terrell) with a badge or a gun,” the city manager told KRQE-TV.

The city manager said Terrell couldn’t be protected as a whistleblower because he made the tapes public.

Chief Burns, on the other hand, gets to keep his job because, the city manager said, there’s no proof he was on duty while he had sex in the ambulance and his actions, while inappropriate, were not illegal.

Follow Zach Noble (@thezachnoble) on Twitter

Like this story? Sign up for "Firewire" to get daily alerts about hot news on TheBlaze.

Thank you for signing up!