Make WordPress Core

Opened 7 years ago

Last modified 6 years ago

#42614 new defect (bug)

Customize: Changesets can still be previewed even after having been published

Reported by: westonruter's profile westonruter Owned by:
Milestone: Future Release Priority: normal
Severity: normal Version: 4.7
Component: Customize Keywords: needs-patch
Focuses: Cc:

Description

Steps to reproduce:

  1. Change the site title to “First Changeset”
  2. Save Draft.
  3. Open frontend preview link in a new tab and see “First Changeset” as site title.
  4. Back in Customizer tab, publish the changes.
  5. Change the site title now to “Second Changeset”
  6. Publish the changes.
  7. Go back to the frontend preview in the other tab and reload.

Bug: notice the first changeset is still able to be previewed even though it it is published (or rather, trashed, since in core a published changeset by default is immediately trashed for garbage collection if revisions support is not enabled).

Note however that if you click the “Customize” link in the admin bar from the published changeset frontend preview, you'll land on the Customizer with an error (from customize.php):

This changeset cannot be further modified.

It seems something similar should be done for changesets on the frontend. I can see a case for why being able to preview a changeset with a publish status could be useful. For example, if revisions are enabled for changesets, it could indeed be useful to preview an old published changeset to see old changes re-applied. However, when a published changeset goes straight to trash, these do not seem they should be able to be previewed.

Should attempting to preview a trashed changeset be silently ignored or should there be an error message like when accessing customize.php with a trashed changeset?

Attachments (2)

42614.0.diff (707 bytes) - added by westonruter 7 years ago.
Screen Shot 2018-01-15 at Mon Jan 15 4.04.15 PM.png (154.0 KB) - added by designsimply 7 years ago.

Download all attachments as: .zip

Change History (6)

@westonruter
7 years ago

#1 @johnbillion
7 years ago

  • Milestone changed from 4.9.1 to 5.0

#2 @designsimply
7 years ago

Tested and confirmed using the steps provided. There error I saw was slightly different:

This changeset has already been published and cannot be further modified.


Seen at http://madefortesting.com/wp-admin/customize.php?url=http%3A%2F%2Fmadefortesting.com%2F&changeset_uuid=ab02554c-9f4c-4cb0-b083-5e3c448a8f7c running WP 4.9.1 and tested using Opera 50.0.2762.58 on macOS 10.13.2.

#3 @johnbillion
6 years ago

  • Milestone changed from 5.0 to 5.1

#4 @pento
6 years ago

  • Keywords needs-patch added
  • Milestone changed from 5.1 to Future Release

I don't like the idea of adding another error.

It seems like it would be better to handle this by creating a new changeset based on the old, and perhaps showing an appropriate message to indicate what's happened.

Note: See TracTickets for help on using tickets.