Although Mindy Kaling and B.J. Novak wrote this together, much of their dialogue was improvised and mirrors how the two (former couple turned best friends) talk to each other in real life. Ike Barinholtz (Morgan) said in an interview that the dinner date between them was produced by them going off-script except for the mentions of the Jamie character's female best friend. In addition, Kaling improvised the Indiana Jones bit in the final scene, with the only scripted element retained is that Mindy and Jamie would decide to go another date.