Despite reporters' objections, Judge Steven T. O'Neill granted Miller's request to close that portion of the hearing.
Issuing his ruling Wednesday, O'Neill would not give details of Miller's testimony but said: "Suffice it to say, they had a special relationship."
Despite that "special relationship," O'Neill ruled that the advice Miller gave was "compassionate," and that the defendant's statement was voluntary.
Desrivieres is charged with first-degree murder, robbery, and related counts in the stabbing deaths of Marc Winchell Estiverne, 23, and his girlfriend, Shamara Hill, 26.
Desrivieres and Estiverne, both Haitian immigrants, were close friends who used to sell drugs together in North Jersey, according to the defendant's confession.
They were renting rooms in a house on the 1200 block of Arch Street in Norristown, and Hill would often stay over.
Police were called to the house June 17, 2012, after the two bodies were found. A forensic investigation showed one of the bodies had been moved and blood had been cleaned from the floor and hallway, according to prosecutors.
The landlords told police they heard a struggle the night of June 14, and "the next morning the owners observed the defendant taking trash bags upstairs and then leave . . . with a trash bag to 'do laundry,' " according to the Montgomery County District Attorney's Office.
Norristown police, Montgomery County detectives, and federal authorities tracked Desrivieres to his mother's house in Irvington, where U.S. marshals found him hiding under a cardboard box in the basement, prosecutors said.
The arrest warrant issued in June alleged that Desrivieres was a member of the Bloods gang in North Jersey.
Desrivieres told police the killing was done in self-defense. According to his statement, Estiverne began punching him after Desrivieres overheard him having a conversation about "snitching."
Due to court orders, attorneys would not discuss the nature of Miller's testimony. But in April 2011, he testified against a group of Haitian immigrants accused of selling crack cocaine in Irvington.
Contact Jessica Parks at 610-313-8117, email@example.com, or follow on Twitter @JS-Parks.