Good. Hotels and hostels are for tourists, apartments should be for residents.
Tourism is good for Spain, that's not lost on anyone. But the profits are not evenly distributed. Not all social problems can be solved by the market.
If my friend can rent her apartment for some amount of money and it helps her to survive jobless periods, why she (or I) should bother that somebody is doing it on the larger scale for larger profits? Good for them. And preventing these profits by prohibiting AirBnb will also kill her small income stream, which is way more important to her than it is for the rich guys (who will just invest freed money to something else).