The Payroll Protection Program, the massive plan Congress passed to help small businesses during the coronavirus economic crisis, has not had the best time of it. The PPP's rollout was a logistical mess, then it ran out of money way too soon and had to be restocked by a second bill. Now it turns out a fair number of "small businesses" that weren't actually all that small gobbled up some of the funding.

The burger chain Shake Shack, which has 120 locations and $100 million in cash to burn, got $10 million from the PPP. Ruth's Hospitality Group, which owns a successful steakhouse chain, got $20 million. The Los Angeles Lakers, who technically fall under the PPP's 500-employees-or-less threshold, but who are also worth about $3.7 billion, got a $4.6 million loan from the program. These news stories sparked widespread outrage, and those companies have since said they would return the loans. But other big companies that slipped in are holding onto their money.

As justified as the anger over these companies carving off slices of the PPP is, it should also be directed at the proper target: How lawmakers designed the Payroll Protection Program in the first place. More specifically, the two key problems are how the PPP was funded, and how actual access to the program worked at the institutional level.

First off, Congress shouldn't have limited PPP funding to a specific dollar amount.

Technically, what the PPP did was provide loans to small businesses via the private banking system. But the idea was that the bulk of the loans would be forgiven so long as the companies used 75 percent of the loans they got to cover payroll expenses and keep their workers employed. That effectively turned most of the loans into one-way grants, which meant Congress needed to provide the money to backstop the one-way transfer. The initial bill gave the program $350 billion to work with, then the second infusion added another $310 billion.

Those loans were designed to cover two and a half months of payroll, but even a cursory glance at small businesses' payroll expenses over that time frame should've made it clear that $350 billion was a woefully inadequate amount. The additional $310 billion is probably still a woefully inadequate amount. Instead, Congress should've just made the program open-ended, without any dollar cap at all. Preserving small businesses through the coronavirus crisis is a specific goal, and we should've designed the PPP to spend however much was necessary to achieve that goal.

Unfortunately, Congress has a lot of people in both parties — though Republicans especially — who are (wrongly) fixated on limiting federal borrowing. So open-ended spending on the PPP was a no-go. The problem is that, if you preemptively limit the pot of money on offer, of course the most powerful of the eligible businesses will get to it first, with nothing but their own consciences to stop them. And a lot of the most vulnerable small businesses will get nothing at all.

Now, it's technically not clear how much of the PPP funding these bigger "small businesses" depleted; Forbes looked at 71 publicly traded companies that got loans through the PPP, and their slice only accounted for 0.09 percent of the money available. But the fact that they got help while many, many smaller businesses got nothing at all points to the inherent absurdity of a spending cap on the program.

The second problem was the actual pathway used to deliver the PPP loan. Congress may have authorized the program, and the Small Business Administration (SBA) may have overseen it with help from the Treasury Department, but it was private banks that originated the loans and handled the actual interactions with the firms that applied for them. And that meant the businesses most likely to get the best, fastest service were the ones that had taken out loans from the banks before, and had good relationships established with the banks already. (That the SBA is a relatively small agency not known for efficiency didn't help either, nor did the archaic web portals and systems it provided the banks for administering the PPP.) This inevitably meant companies that were on the bigger, wealthier, and better connected end of the small business population. It also meant small businesses that come from more privileged populations: Black and Latino small businesses have historically been shut out of and ignored by the financial system to a disproportionate degree, and reports suggest the distribution of the Payroll Protection Program's funds was no different. (Though the Treasury Department is not officially tracking that data.)

There were other institutional pipelines lawmakers could've used that didn't run through the SBA and the private banks. They could've just skipped the whole concept of originating the money as loans that are then forgiven, and relied on the Treasury Department to directly provide the money as grants through something like the payroll system that small businesses already have to interact with. In the House, Rep. Pramila Jayapal (D-Wash.) has a bill that would more or less do just that, and Sen. Bernie Sanders (I-Vt.) and others in the Senate have similar companion legislation.

There were other problems, too. Insisting that 75 percent of the PPP loans be used to cover payroll left out a lot of small businesses whose expenses are mainly location or facilities or other physical capital. Better to just tell businesses that all the money is free and they can use it however they want, as long as they keep everyone on payroll. The PPP also explicitly looked at individual locations to meet the 500-workers-or-less threshold, as opposed to the overall company, which is how the big chain restaurants snuck in there.

It was also cumbersome for Congress to design two different rescue packages — one for "small" businesses and one for "big" ones. It should've just done one big package that covered everyone. As with money aid to individuals and households, money aid to companies tends to work better when the program is as simple and universal as possible. Jayapal's bill would move things closer to that goal in some of these other ways as well.

Obviously, standing up a giant rescue package for millions of companies in the midst of a pandemic and an economic collapse is no easy feat. But Congress also committed a lot of unforced errors with the Payroll Protection Program. Now America's small businesses must live with the consequences of those mistakes — the smallest and least privileged businesses most of all.

Want more essential commentary and analysis like this delivered straight to your inbox? Sign up for The Week's "Today's best articles" newsletter here.