Appeal from Circuit Court of Macon County. No. 01CF616. Honorable Lisa Holder White, Judge Presiding.
 The opinion of the court was delivered by: Justice McCULLOUGH
 On March 10, 2001, the State charged defendant, Chad A. Junior, and co-defendant, Aaron Settle, by information with two counts of burglary (720 ILCS 5/19-1(a) (West 2000)) and one count of residential burglary (720 ILCS 5/19-3 (West 2000)). Settle pleaded guilty to all charges. Defendant pleaded not guilty, and a jury trial was held in December 2001. The jury found defendant guilty of two counts of burglary. The jury could not reach a unanimous verdict on the residential burglary count, and the trial court declared a mistrial. Defendant filed a motion for a new trial, which the court rejected. On February 21, 2002, Judge Lisa Holder White sentenced defendant as a Class X offender to concurrent 10-year prison sentences on the burglary convictions. On the State's motion, the court also dismissed the residential burglary charge. Defendant petitioned the court to reconsider his sentence. The court denied the motion and held his sentence was appropriate.
 Defendant appeals, arguing (1) his due-process rights were violated when the State used and failed to correct Settle's perjured testimony, (2) he was denied effective assistance of counsel because Public Defender Jon Baxter represented both him and Settle at their joint preliminary hearing, and (3) his trial counsel, Assistant Public Defender David Massey, labored under a conflict of interest because his law partner, Baxter, represented both Junior and Settle at their joint preliminary hearing. We reverse and remand for a new trial.
 At approximately 1 a.m. on March 5, 2001, Skyler Kaufman, Sebastian Santos, and Daniel French were sitting on Kaufman's front porch waiting to catch some of their friends who were supposed to "prank" French's house down the street. The boys noticed a white vehicle they initially thought belonged to their friends driving slowly in the neighborhood. They hid but continued to watch as the vehicle drove around the neighborhood and parked.
 The boys saw two men get out of the vehicle. At trial, they testified one man was wearing a red-hooded sweatshirt and the other had a long ponytail. At trial, none of the boys could identify defendant as one of the men who got out of the vehicle.
 The boys watched the men break into a black Jeep that belonged to a neighbor and try to break into garages in the neighborhood. The boys awakened Kaufman's father, Tom Kaufman, who called the police and then went outside to wait with the boys. Before the police arrived, Tom saw the two men walking down the street. One man was carrying what looked like a bag, and the other was pushing an object. When the two men noticed Tom, they dropped what they were carrying and ran in between some houses.
 Tom and the boys remained outside until the police arrived. The boys told Officer Steve Young what they had witnessed and took him to the white car. As they were talking, Settle approached the white car. Kaufman and Santos identified Settle as one of the men they saw break into the Jeep. Officer Young approached Settle, who initially said his wife had car trouble and he was looking for her car. Settle then admitted he and defendant had been burglarizing vehicles and garages in the area.
 Officers recovered and returned a coat, compact discs, and a camera taken from Christian Sassano's Jeep, a power washer and chain saw taken from William Shorter's detached garage, and a plastic gas can taken from Kathy Powell's attached garage.
 Both defendant and Settle were charged with the counts outlined above. At their arraignment, Settle told the trial court, "[t]his man was with me earlier this day. At the time of the offense, it was a different person that was with me." At their joint preliminary hearing, defendant and Settle were represented by Baxter. After the State had presented its evidence, the following exchange took place between Settle and the court:
 "SETTLE: I want to make a statement. This my codefendant. He wasn't even there.
 COURT: Sir, you have asked to have a lawyer appointed and we have done that. You must speak through your lawyer. If you want to represent yourself, we will take away your lawyer. Can't have it both ways. Do you want a lawyer in the case?
 The trial court found probable cause to believe defendant and Settle committed the burglaries. Both men pleaded not guilty. The court appointed Massey to represent defendant and Assistant Public Defender Thomas Wheeler to represent Settle.
 On July 25, 2001, Settle and the State's Attorney's office entered into a plea agreement. In exchange for Settle's guilty pleas on all three counts and his testimony against defendant, the State promised to seek concurrent, not consecutive, sentences.
 On December 10, 2001, defendant's trial began. Settle testified defendant was with him on the morning of March 5, 2001, and together they burglarized the Jeep and two garages. He testified defendant owed him money and they went out that night to get that money. Settle recanted earlier statements, including a written statement, where he indicated defendant was not involved in the burglaries. He testified he made the statements because he had been threatened by his brother and defendant.
 When questioned on direct, Settle testified he had not been promised anything in consideration for his testimony. During cross-examination, when defense counsel challenged this assertion, Settle claimed he was testifying only because he was subpoenaed. During closing arguments, the prosecutor argued if Settle and the State's Attorney's office had made a deal, ...