One of the many episodes of Castle (2009) in which an alumni of the "Whedon-Verse" appears alongside Nathan Fillion. D.B. Woodside, who plays Lance Carlberg in this episode, appeared alongside Nathan Fillion in the seventh and final season of Buffy the Vampire Slayer (1997).
Castle mentions a "Desperate Housewives" situation. Nathan Fillion was a cast member of the Desperate Housewives series.