#### THE PEOPLE OF THE STATE OF ILLINOIS, Plaintiff-Appellee, v. CHARLIE GORDON LYNN, Defendant-Appellant.

Third District

No. 3 — 90—0840

Opinion filed January 16, 1992.

*689Verlin R. Heinz, of State Appellate Defender’s Office, of Ottawa, and Daniel D. Yuhas, of State Appellate Defender’s Office, of Springfield, for appellant.

Edward Burmila, Jr., State’s Attorney, of Joliet (John X. Breslin and Rita Kennedy Hertel, both of State’s Attorneys Appellate Prosecutor’s Office, of counsel), for the People.

JUSTICE STOUDER

delivered the opinion of the court:

The defendant, Charlie Gordon Lynn, appeals his conviction for official misconduct (Ill. Rev. Stat. 1989, ch. 38, par. 33 — 3). We affirm.

The record shows that the defendant was initially charged with official misconduct and attempted unlawful delivery of over 15 grams of a controlled substance (Ill. Rev. Stat. 1989, ch. 38, par. 8 — 4; ch. 561/2, par. 1401). At trial, Officer Ronald Wilson testified that Albert Dixon, an inmate at the Stateville Correctional Center, had told authorities that a prison employee was willing to smuggle narcotics into the prison. Wilson decided to set up an undercover operation in which he would pose as Dixon’s brother and ask the employee to deliver narcotics to Dixon.

On December 18, 1987, Wilson called a telephone number supplied by Dixon and spoke to the defendant. The defendant agreed to deliver narcotics to Dixon. He said his fee would be one-half of the drugs delivered.

Wilson further testified that he had three more telephone conversations with the defendant concerning the transaction. Thereafter, on December 29, 1987, Wilson and Officer Brandon Brown met the defendant at a gas station. They later drove to the defendant’s residence. Wilson was wearing a listening device, and a recording of the conversation they had that day was played to the jury. On the tape, the defendant stated that he was homosexual. He also said that he could discourage a thorough search of his person by pretending to enjoy it.

*690Since the tape was sometimes difficult to understand, the trial court allowed the State to question Wilson about the conversation. The prosecutor asked if the defendant said he had any means of preventing a thorough search. Wilson replied that the defendant told him he could do so by asking the guard to press harder. The prosecutor then asked if the defendant had indicated his sexual preference. After defense counsel objected, the parties had an off-the-record discussion with the trial court. The prosecutor then asked a different question.

Wilson further testified that the defendant said he would smuggle the cocaine into prison by hiding it in his boots. The defendant believed that the person searching him would not keep his boots off for long because of his foot odor. He also told Wilson to package the cocaine in small bundles and not use any metallic tape. As payment, they agreed that the defendant would receive between $100 and $200 as well as one-eighth ounce of cocaine.

On December 30, 1987, Wilson and Brown went to the defendant’s home. Wilson gave the defendant $100 and two packages of a substance resembling cocaine. One package contained 14.1 grams, and the other contained 7.2 grams. After the defendant received the items, he was arrested.

After Wilson’s testimony, the prosecutor stated that he had made an error in the amount of cocaine charged in the attempted unlawful delivery count. He therefore dropped that count.

Officer Brown then testified about his role in the case. His testimony was generally consistent with Wilson’s testimony.

Barbara Miller testified that she was a nursing supervisor at Stateville. She sometimes supervised the defendant, who was a medical technician. One of the defendant’s responsibilities was to deliver medication to the prisoners. When he did so, he walked freely throughout the prison without carrying a special pass.

Miller further testified that the guards were supposed to thoroughly search everyone who entered the prison. However, about once a week the guards allowed her to enter without a search. She estimated that in the past seven years, on about six occasions she was required to remove her shoes during the search.

Venetta Foulks-Wright testified that she was a correctional lieutenant at Stateville. On more than one occasion, the defendant told her that inmates had harassed him about bringing contraband into the prison. She advised him to file an incident report. When she examined the defendant’s shoes at trial, she said that the metal arch supports would trigger the metal detector. The defendant would then be required to remove his shoes for examination.

*691Following the close of proofs, the jury found the defendant guilty of official misconduct.

On appeal, the defendant first argues that he was improperly convicted of official misconduct. Official misconduct occurs where a public employee, acting in his official capacity, solicits or knowingly accepts a fee or reward which is not authorized by law for the performance of any act. (Ill. Rev. Stat. 1989, ch. 38, par. 33 — 3(d).) The defendant argues that the State failed to show that he was acting in an official capacity when he agreed with Wilson to deliver the cocaine.

An act is performed in a public officer’s official capacity if it is accomplished by exploitation of his public position. (People v. Kleffman (1980), 90 Ill. App. 3d 1, 412 N.E.2d 1057.) The offense of official misconduct was designed to reach those situations where a public officer or employee has exploited his official position to the detriment of the public good. People v. Steinmann (1978), 57 Ill. App. 3d 887, 373 N.E.2d 757.

The record shows that the defendant agreed to deliver cocaine to Dixon. As a prison medical technician, he had regular access to the prison and its inmates. He was also familiar with the search procedures. It is clear that his status as a public employee was integral to the drug transaction. We therefore hold that he could have been properly found to have acted in an official capacity when he agreed to deliver the cocaine.

The defendant next argues that the prosecutor improperly implied that the defendant was homosexual when he examined Wilson about the tape. The defendant bases his argument on the prosecutor’s questions about his sexual preference and whether he had indicated that he could avoid a thorough search.

The State first notes that the evidence objected to was also contained on the tape. Before the tape was played, the defendant did not object on the grounds that it contained evidence of his homosexuality. The State further notes that the record does not contain a final ruling on the defendant’s objection to the question about his sexual preference. Accordingly, the State argues that the issue was waived. We find, however, that the issue has been preserved because the defendant made a contemporaneous objection to the questioning and raised the issue in his post-trial motion. See People v. Enoch (1988), 122 Ill. 2d 176, 522 N.E.2d 1124.

Evidence of a defendant’s homosexuality is admissible if it is relevant to the case. (People v. Sales (1986), 151 Ill. App. 3d 226, 502 N.E.2d 1221.) Here, the question about the search was relevant be*692cause it shed light on how the crime was to be committed. The question about the defendant’s sexual preference was arguably irrelevant. However, it was not prejudicial because the objection was apparently sustained and the "witness did not answer it. We therefore find no error.

The judgment of the circuit court of Will County is affirmed.

Affirmed.

HAASE and McCUSKEY, JJ., concur.