(Bloomberg) -- Hertz Global Holdings Inc. shareholders have officially notched an improbable win. If not for U.S. regulators, the victory could have been twice as sweet.

All told, Hertz’s bankruptcy exit plan will repay creditors and return more than $1 billion of value to shareholders, lawyer Tom Lauria said on behalf of the company in a Thursday court hearing. But the deal might have delivered more than twice that if Hertz had succeeded in issuing stock to fund its bankruptcy last year, Lauria said.

Hertz was an early favorite of traders on Reddit’s WallStreetBets forum, and the ensuing rally prompted the bankrupt firm to explore selling potentially “worthless” shares to raise cash. Hertz scrapped those efforts after Securities and Exchange Commission officials questioned the unusual approach.

Instead, Hertz had to borrow more money to fund operations, ultimately arranging a $1.65 billion debtor-in-possession loan from the likes of Apollo Global Management. Because all creditors have to be repaid before equity can get anything in U.S. bankruptcy, the additional debt weighed on recoveries for stockholders.

Still, Hertz’s bankruptcy plan is “a fantastic result,” U.S. Bankruptcy Judge Mary Walrath said in hearing Thursday, noting that payouts to equity are virtually unheard of in Chapter 11. The case “surpasses any result that I’ve seen in any Chapter 11 case that I’ve faced in my 20-plus years,” Walrath said.

Hertz shares rose 7% on Thursday, to an intraday high of $7.08 at 11:56 a.m. in New York.

Walrath approved Hertz’s Chapter 11 plan on Thursday, clearing the company’s route out of bankruptcy. Knighthead Capital Management and Certares Management are set to take over the company, having won a heated auction for its assets.

“This case proves that no one, not even the SEC or the New York Stock Exchange, knows the future,” Lauria said in a hearing last month.

The case is Hertz Corp. 20-11218, U.S. Bankruptcy Court, District of Delaware (Wilmington).

©2021 Bloomberg L.P.