olegkoval/magento2-regenerate_url_rewrites

Delete non-existing products/categories lines

Opened this issue · 0 comments

Summary

It would be useful to have an option to also delete the lines of products that no longer exist.
It may happen that products/categories have been deleted but records still exist in the url_rewrite table.

Basic example

We could do something like

php bin/magento ok:urlrewrites:regenerate --entity-type=product --not-existing
php bin/magento ok:urlrewrites:regenerate --entity-type=category --not-existing

... and the process deletes non-existing products/categories