I think you’re conflating the SPAC sponsors and the owners of the public equity. The owners of the equity get their money back (plus interest) if the SPAC doesn’t find a target. The sponsors are out whatever money they put up to form the SPAC, take it public and search unsuccessfully for a target. The sponsors do typically have very rich upside if they find a deal - like, 20% of the post-merger company - but it’s not a risk-free thing for them.
Don’t get me wrong, I think SPACs are fucking stupid and bad for retail investors and I would never want to be involved in one, but the pre-deal owners of shares of the SPAC are actually fairly decently protected (opt-out rights, money held in trust, not liable for SPAC expenses).