Sure, but it really only makes sense to consider cases where:
A) The business has paying customers
B) It's very important to the customers that this product remain available
C) The founder is unwilling to give or license the source code to those customers
In practice, all three of these factors being present is uncommon. Usually if the product is actually important to a customer, they just pay to acquire the assets. And there is usually no reason for a solo founder not to take that deal if the alternative is just shutting down the business.
For a venture backed business, maybe the lawyers decide there is too much legal risk or whatever. But for an indie hacker, that doesn't happen.
We hear stories all the time of folks getting burned when venture backed startups shut down without giving people any time to switch to another product, or sometimes even to expert their data. When is the last time you heard about this happening from the paying customers of a solo founder? Literally never.