Even with morning traffic, you should be able to make your flight if you leave early enough. I would make the most of it and stay in Barcelona. It is such a great city. We always try to add at least a couple of night before and after a cruise just to enjoy the city's great beaches, shopping, restaurants and such.
Hope that helps.