Is It Illegal for Businesses to Refuse to Accept Cash?

A number of viral Facebook posts (including one from Mississippi State Sen. Chad McMahan) claim that it is illegal for businesses not to accept cash payments for goods or services. The posts further claim that when cash is turned down, the debt is legally recognized as paid. These posts come at a time when some businesses are refusing cash payments due to concerns about coronavirus transmission.
Section 31 of U.S. Code 5103 states that “United States coins and currency (including Federal reserve notes and circulating notes of Federal reserve...