A lot of investors, including myself, gave Warren Buffett a good amount of grief during the pandemic. The Oracle of Omaha didn't make some of the exciting moves that people had hoped for and instead continued to hold high levels of cash.

Berkshire also sold a lot of its bank stock holdings, which I still don't quite entirely agree with, although Buffett attributes the decision to not wanting to be too exposed to the sector in case the pandemic worsened.

But one big move Buffett and his company Berkshire Hathaway (NYSE:BRK.A) (NYSE:BRK.B) seemingly nailed is their decision to load up on Bank of America (NYSE:BAC), the country's second-largest bank by assets. Let's revisit this decision and look at why it has worked out so well.

Bank of America has outperformed

In July and early August of 2020, Buffett and Berkshire spent 12 days purchasing roughly $2.1 billion of stock in Bank of America, increasing their already sizable position in the company to nearly 12% of its outstanding shares. Buffett was able to buy shares for average prices ranging from roughly $23.75 to $25.25. The stock recently traded around $46.50 per share. At the end of the second quarter, Berkshire owned more than 1 billion shares of the bank, valued at nearly $47 billion. The company has also received permission from the Federal Reserve to purchase as much as 25% of Bank of America's outstanding shares if it chooses to.

Not only is it impressive that Bank of America stock has nearly doubled since Buffett and Berkshire's big purchases, but it has also outperformed its peers since July of last year.

BAC Chart

BAC data by YCharts.

That's impressive because while all banks were beaten down, Wells Fargo (NYSE:WFC), which has put up a similar return to Bank of America, was trading at such a low valuation, there was really nowhere to go but up, so I think it had more implied upside at the time.

Like most of the industry, Bank of America weathered the pandemic well and maintained strong credit quality. As vaccines were distributed and the world started to resume some level of normalcy, investors piled into banks this year as a reopening play.

But Bank of America stands out among its peers because it is one of the most asset-sensitive banks, meaning more of its assets (such as loans) will see their associated interest rates reprice higher with the federal funds rate than will its liabilities like deposits. Initially, it looked like the Fed might not raise interest rates until 2024, but now many investors think a rate hike could happen sometime next year, with the Fed already beginning to taper its bond purchases. Whenever long-term or short-term rates tick up, Bank of America benefits immensely.

Warren Buffett

Image source: Motley Fool.

Additionally, investors were pleased with Bank of America's Q3 earnings report because the bank saw some signs of renewed loan growth. Management also became more optimistic that the bank will hit a projection it made earlier this year in which net interest income (the money banks make on their loans and securities after covering their cost of funding) would be $1 billion higher in Q4 than it was in the first quarter of the year.

Credit where credit is due

Investors were impatient with Buffett during the pandemic and frustrated at times with his sales, but now it's time to give him credit. He absolutely nailed his pick with Bank of America.

And while the stock now trades at a high valuation, I still think Bank of America will generate consistent returns over time. It's one of the largest commercial lenders in the country (if not the largest), it continues to grow deposits very fast, and its investment banking division keeps getting stronger. So all I have are good things to say about this move by Buffett.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.