>
I see your point but [...] I'd rather not see my search results in the webshop pollutedThere's three issues with this:
1. In UX, hiding things is a lazy solution to not being able to effectively differentiate items by relevance. There isn't an easy one-size-fits-all answer to doing the latter, which is why you need good, experienced UX people. Hiding things is what the inexperienced/lazy/bad ones do instead.
2. "Polluted" is also a codeword for "not of the clean, white, zero-inbox aesthetic I desire", and in certain situations this excuse is overused to enormously degrade UX in favour of a contrived sense of visual "cleanliness". A functional UI shouldn't be "clean", it should contain all the information you need to see (in a clear, differentiable, non-confusing way).
3. This is a stretch, but I think ideal system would differentiate between "currently out of stock" and "discontinued", and filtering out the latter is slightly less of a glaring issue.