diff --git a/src/wp-admin/js/customize-controls.js b/src/wp-admin/js/customize-controls.js index 365a99d8d6..a51fb02e10 100644 --- a/src/wp-admin/js/customize-controls.js +++ b/src/wp-admin/js/customize-controls.js @@ -3466,7 +3466,12 @@ initialize: function( id, options ) { var control = this, deferredSettingIds = [], settings, gatherSettings; - control.params = _.extend( {}, control.defaults ); + control.params = _.extend( + {}, + control.defaults, + control.params || {}, // In case sub-class already defines. + options.params || options || {} // The options.params property is deprecated, but it is checked first for back-compat. + ); if ( ! api.Control.instanceCounter ) { api.Control.instanceCounter = 0; @@ -3487,7 +3492,6 @@ } ); } - _.extend( control.params, options.params || options ); if ( ! control.params.content ) { control.params.content = $( '
  • ', { id: 'customize-control-' + id.replace( /]/g, '' ).replace( /\[/g, '-' ),