johngodley / redirection

Manage all your WordPress 301 redirects and monitor 404 errors
https://redirection.me
GNU General Public License v3.0
558 stars 139 forks source link

Stop URL Monitor from creating redirections for deleted attachments #3566

Open galbaras opened 1 year ago

galbaras commented 1 year ago

Redirection seems to be monitoring every post type, so it creates deletion redirects for customizer sets, attachments and other things that just overload the redirection tables.

Possible solution 1: exclude these specific post types from being monitored.

Possible solution 2: provide a plugin setting to determine which post types to monitor (this one should detect all the types first)

johngodley commented 5 months ago

It should only monitor the post types you configure in the options. I've been unable to trigger anything for attachments or other things. Could you show me what monitor settings you have, and list the steps to cause something to be created?

galbaras commented 5 months ago

On one site, I have Monitor changes to posts, pages, products, testimonials & trash turned on, and I see these redirections:

image

If anything, both of these might be attachments, which shouldn't be monitored.

On another site I have posts, pages, products an trash enabled, and the following redirections:

image

On a third site, the plugin moniors, posts, pages, products, portfolio items and trash, and besides deleted post types, I also see this, which I think might be drafts:

image

2 more examples from other sites, both looking like post drafts:

image

image

I've had quite a number of redirections similar to these, but I've removed them, so don't have them anymore (sorry).

johngodley commented 5 months ago

Thanks. I think this may be something with a particular setting, or maybe even a plugin. I've tried everything but just can't trigger anything to be created.

galbaras commented 5 months ago

Given the generated redirections all go to / and are disabled, I'd say the setting involved is trash monitoring. What's the trigger for that action?