Ideally, they should have stopped selling tickets and then stopped the flights when the sold flights were done. At least within some time frame like 1 month
Unfortunately continuing to burn money with no hope of recovery is not a popular strategy among judges and creditor's lawyers. Customers will either get refunds or join the back of the creditor line.
I doubt many people would buy tickets for a flight with a failing airline. That said, shutting down with effectively zero notice is pretty terrible, and they will probably need to do a bunch of repositioning flights, so they could have kept the lights on for one or two more days.