Mr Whittall had faced 12 charges related to failing to ensure the safety of workers in the mine, but they were dropped in December 2013, after the informant, the Ministry of Business, Innovation and Enterprise, offered no evidence.
Christchurch District Court judge Jane Farish had agreed a successful prosecution was unlikely.
A proposal that Mr Whittall, on behalf of the directors and officers of the former Pike River Coal, would pay families a share of $3.41 million was then carried out.
Families were not told of the prosecution's decision until after it had been made.
Anna Osborne, widow of contractor Milton Osborne, and Sonya Rockhouse, mother of miner Ben Rockhouse, subsequently applied for a judicial review of the decision to drop charges, which was heard in the High Court this week.
WorkSafe NZ lawyer Joanna Holden said the prosecutor had initially been concerned about the legality and propriety of the unusual compensation offer. However, after careful consideration the concerns were ruled to be unfounded.
Ms Holden said the prosecutor was likely to have been criticised if the compensation was not considered and the prosecution later failed or was dropped.
Family members at court yesterday wore yellow ribbons, a symbol of the tragedy, and long-time family spokesman Bernie Monk was in attendance.
Nigel Hampton, QC, lawyer for the families, argued that the compensation was "chequebook justice", funded by the insurance company's payout from the sale of Pike River.
He said a deal was struck between the prosecution and defence for Mr Whittall's charges to be dropped if the insurance money was paid.
Read more:
• Pike River: Judicial review into charges wraps up
• Review into decision to drop charges against former Pike River boss
• Westport: Built on black gold
• Pike River survivor recognised for bravery
"Pragmatism overcame principle ... and following the money coloured everything ... [this was] a disastrous message to allow to be sent to the public - that justice in this country can be bought."
Justice Farish had previously ordered Pike River Coal to pay reparations, which the company said it could not meet.
That experience meant Justice Farish was too focused on ensuring compensation was paid, Mr Hampton argued.
"This was a District Court judge following a line I suggest she shouldn't have been following at all."
Justice Brendan Brown has reserved his decision.
Search for justice
• November 2010: A series of explosions at Pike River coal mine kills 29 men.
• December 2013: Charges are dropped against Peter Whittall after government lawyers offered no evidence, and compensation offered by Mr Whittall's legal team is paid to families.
• May 2014: A judicial review of the decision to drop the charges is heard at Wellington High Court, after an application by two Pike River families. The court's decision has been reserved.