A New Jersey appeals court ruled Thursday that it was improper for a city police officer in Wildwood to hold elected office at the same time.

It was also wrong for Gary DeMarzo to get himself laid off from the force in order to resolve the conflict and to then put himself on a special first-to-be-rehired list should he lose his elected office, the court said.