After enduring a long, steady drip of Silicon Valley hype, bankers may be forgiven for savoring a moment of schadenfreude over the newfound troubles of online lenders.

One after another, some of the biggest names in marketplace lending have been humbled in recent weeks. Lending Club, after ousting its founder and chief executive officer amid scandal, is now under investigation by the Justice Department. Prosper Marketplace and Avant announced job cuts. OnDeck Capital reported a $12.6 million quarterly loss while signaling that the rest of the year does not look much better.

All of these setbacks are connected to a rather sudden reversal in sentiment among the institutional investors who fueled the rapid rise of the online lending sector.

Still, banks would be unwise to dismiss digital lending as a passing fad. Startups after the financial crisis built more efficient processes for approving borrowers, while also delivering better customer experiences. Those breakthroughs will surely endure, even if some of the companies that pioneered them do not.

"The consumer still wants this product," said Anthony Hsieh, the CEO of the online mortgage lender LoanDepot.

And there's a second reason why the banking industry can ill afford to crow. During the go-go days of marketplace lending, many banks became key cogs in the machine. Some of those banks now appear likely to suffer alongside their online brethren.

What follows is an analysis of how banks that have adopted various postures toward the marketplace lending industry are likely to be affected by the recent shakeout.

Banks that issue loans for marketplace lenders. Several small banks, including WebBank and Celtic Bank in Utah and Cross River Bank in New Jersey, made themselves indispensable to the rapid growth of online lending. They are probably the banks with the most to lose.

Over the last few years, so-called issuing banks developed symbiotic relationships with marketplace lenders. Their banking licenses allowed the digital lenders to avoid state-by-state interest rate caps, which helped fuel the sector's phenomenal growth. For the banks, the relationships could be quite lucrative.

But assuming the online lending industry is now in the midst of a substantial contraction, revenues at these banks will likely sustain a significant hit.

The lending slowdown comes at a time when both judges and regulators are starting to express skepticism about these partnerships. So for this group of small banks, which have been riding the marketplace lending wave, the good times may have been about to come to an end, anyway.

Banks that sought help from marketplace lenders in order to stay relevant to their customers. These institutions recognized that they were at risk of falling behind the times and decided that the fastest way to adapt was by partnering with a marketplace lender.

Examples of banks that adopted this approach include JPMorgan Chase, Regions Financial and the $778 million-asset Radius Bank.

The partnerships take different forms. Some of the banks operate cobranded websites, built with an online lender's loan-underwriting tools, where the bank's own customers can apply for credit. Other banks rely on an online lender's technology, but in ways that are invisible to the customer.

Today, one potential risk for these banking institutions involves the possibility that their partner will have to shut its doors. Another possible pitfall involves reputational risk. If a digital lender gets a black eye – or if that is the perception of banking regulators – it could harm the partner bank.

"A bank's regulators are going to be looking at any companies that they partner with," said Alex Johnson, an analyst at Mercator Advisory Group.

Banks that are buying loans from marketplace lenders. This category ranges from some the biggest names on Wall Street all the way down to small community banks.

These institutions saw an opportunity to make an investment profit by buying the loans underwritten by marketplace lenders. In some cases they held that debt on their own balance sheets. In other instances, they bought loans with the intention of bundling them into bonds and reselling them.

If more consumers and small-business borrowers start missing their payments on these loans, the banks that bought them may be vulnerable. Credit performance in the industry has recently started to worsen, as loans to borrowers with lower credit scores are showing signs of deterioration.

But these arrangements are more transactional than strategic for the banks that entered them, which means that they should be relatively easy to exit cleanly.

As Lending Club's stock price plummeted earlier this month, Citigroup reportedly refused to provide support. In addition, a consortium of more than 200 small banks halted its purchases of Lending Club loans, at least temporarily.

In the end, the purchasing banks may have more leverage over the troubled online lending platforms than the other way around.

"I think that Lending Club would have to work hard to regain the trust of banks. That's for sure," said James Wu, the chief executive of MonJa, an analytics firm that caters to institutional investors.

Banks that hope to acquire an online lender. It is unclear how many banks will pursue this strategy. So far, it has not been a popular option, as banks were scared off by the sky-high valuations that venture capitalists assigned to lending startups.

But in the current environment, the price tags on these companies seem likely to fall. "The calculus for many bankers on how to approach alternative lending is changing rapidly," Javelin Advisory Services wrote in a report published last week.

Banks that waited for the right acquisition opportunity allowed their competitors to get a head start. But their patient approach may yet be vindicated.

Banks that built their own lending platforms. Wells Fargo and Goldman Sachs are among the banks that eschewed partnerships with online lenders and instead went it alone.

This approach has taken longer to get off the ground than some partnerships involving rival banks did. But in light of the recent upheaval in the online lending sphere, building a platform internally looks like a smart approach.

Banks that built their own platforms should be able to marry the banking industry's stable, low-cost funding base with at least some of the advantages pioneered by marketplace lenders.

"It does seem like the tide is turning back toward banks, which we think is great," said Dan O'Malley, chief digital officer at Eastern Bank in Boston, which built its own small-business loan platform.

Referring to the recent upheaval in online lending, he said: "We're not surprised by this. We've expected it."