Make WordPress Core


Ignore:
Timestamp:
01/22/2018 06:48:51 AM (7 years ago)
Author:
westonruter
Message:

Customize: Prevent frontend previewing from causing a customization lock on the changeset.

Props dlh.
Amends [41839].
See #42024.
Fixes #42975.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-manager.php

    r42538 r42541  
    608608     *
    609609     * @since 4.9.0
     610     * @global string $pagenow
    610611     */
    611612    public function establish_loaded_changeset() {
     613        global $pagenow;
     614
    612615        if ( empty( $this->_changeset_uuid ) ) {
    613616            $changeset_uuid = null;
     
    638641        }
    639642
    640         $this->set_changeset_lock( $this->changeset_post_id() );
     643        if ( is_admin() && 'customize.php' === $pagenow ) {
     644            $this->set_changeset_lock( $this->changeset_post_id() );
     645        }
    641646    }
    642647
Note: See TracChangeset for help on using the changeset viewer.