Make WordPress Core

Ticket #42415: 42415.1.diff

File 42415.1.diff, 1.3 KB (added by westonruter, 9 years ago)
  • src/wp-admin/js/customize-controls.js

    diff --git src/wp-admin/js/customize-controls.js src/wp-admin/js/customize-controls.js
    index 7fb87bc88e..657f003a66 100644
     
    82228222
    82238223                // Set up initial notifications.
    82248224                (function() {
     8225                        var removedQueryParams = [];
    82258226
    82268227                        /**
    82278228                         * Obtain the URL to restore the autosave.
     
    83188319
    83198320                        if ( api.settings.changeset.autosaved ) {
    83208321                                api.state( 'saved' ).set( false );
    8321                                 stripParamsFromLocation( [ 'customize_autosaved' ] ); // Remove param when restoring autosave revision.
    8322                         } else if ( ! api.settings.changeset.branching && 'auto-draft' === api.settings.changeset.status ) {
    8323                                 stripParamsFromLocation( [ 'changeset_uuid' ] ); // Remove UUID when restoring autosave auto-draft.
     8322                                removedQueryParams.push( 'customize_autosaved' );
     8323                        }
     8324                        if ( ! api.settings.changeset.branching && 'auto-draft' === api.settings.changeset.status ) {
     8325                                removedQueryParams.push( 'changeset_uuid' ); // Remove UUID when restoring autosave auto-draft.
     8326                        }
     8327                        if ( removedQueryParams.length > 0 ) {
     8328                                stripParamsFromLocation( removedQueryParams );
    83248329                        }
    83258330                        if ( api.settings.changeset.latestAutoDraftUuid || api.settings.changeset.hasAutosaveRevision ) {
    83268331                                addAutosaveRestoreNotification();