Problem/Motivation

It appears that when you have already existing live/indexed/published content, and you are using Content Moderation to create a new, unpublished revision of that content, that XML sitemap is using that latest version for indexing, and so it's saving the link in the table as unaccessible (since drafts are not published to anonymous users generally).

Proposed resolution

We need to check our entity indexing code to see if the current entity object is considered the current/live revision, and if not, skip indexing.

User interface changes

None

API changes

None

Data model changes

None

Issue fork xmlsitemap-3252329

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Dave Reid created an issue. See original summary.

dave reid’s picture

Status: Active » Reviewed & tested by the community

I tested the update hook on two different sites, one that had about 20 items that needed to be corrected, and it worked as expected. My hope is that this impact is minimal on larger sites.

  • Dave Reid committed 7ebdd9d on 8.x-1.x
    Issue #3252329 by Dave Reid: Creating new draft revisions of already...
dave reid’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.