Update:
after making the suggested change, I now have two problems...
before, by clicking on a sold out product, you could still see the technical sheet.
Now, the page refreshes and takes you to the home page.
Second problem...
before editing, by clicking on the main category, compare all the products I had selected...
Now,if I select the main category...i just get a refresh