An officer who makes improper use of his or her office for the purpose of gaining an advantage is guilty of an offence.