Apu sells Homer a beer keg for the American Civil War reenactment of the Battle of Springfield. At the reenactment, Principal Skinner watches as Springfielders disobey him and hold a rather inaccurate battle (featuring an orange plaid clad "East" faction, a roller skating Stone Wall Jackson, and a giant robotic spider made by Professor Frink). After the battle, Homer brings the empty, dented keg back to Apu at the Kwik-E-Mart in an attempt to get the deposit. There, he hears a giggle coming from a closet and finds Apu making love with the woman who delivers Squishees to Kwik-E-Mart. He then walks backwards in shock all the way home to his bed and then dreams about walking backwards when he falls asleep.
Marge figures out what Homer saw from the movements of his pupil. They decide not to tell Manjula but while they are playing Badminton Homer and Marge act awkwardly with Manjula and Apu looking at them, trying not to give out hints Apu cheated on Manjula. They then confront Apu and he says he will break up with the Squishee Lady named Annette. However, he breaks his promise (as it gets his mind off the octuplets). Later, Manjula watches the surveillance footage of Apu cheating. To help get them together, Homer and Marge invite them both to dinner, but do not tell them that the other one is coming. After a failed attempt with Bart and Lisa, Apu tries to promise to Manjula that he will change, but Manjula refuses to listen and demands a divorce.
Kicked out, Apu moves into the apartment complex where Kirk Van Houten lives. The octuplets then speak their first words, which put together, say "Mommy, will you let daddy come back...cookie!" Marge and Manjula go to Apu's and arrive in time to prevent him from committing suicide by hanging. Apu is then subjected to several tasks to redeem himself (such as eating a light bulb), though Manjula says it will take time for everything to get back to normal. In bed, Manjula, finally satisfied with what he has done, kisses Apu while Homer watches from the window, on a ladder. The couple continues and Homer, traumatized, hops backwards on the ladder all the way home, without falling, mimicking what he did earlier.