Changeset 34057
- Timestamp:
- 09/11/2015 08:15:41 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/4.3/src/wp-admin/js/customize-controls.js
r33942 r34057 2164 2164 */ 2165 2165 setImageFromAttachment: function( attachment ) { 2166 var icon = typeof attachment.sizes['site_icon-32'] !== 'undefined' ? attachment.sizes['site_icon-32'] : attachment.sizes.thumbnail; 2166 var sizes = [ 'site_icon-32', 'thumbnail', 'full' ], 2167 icon; 2168 2169 _.each( sizes, function( size ) { 2170 if ( ! icon && ! _.isUndefined ( attachment.sizes[ size ] ) ) { 2171 icon = attachment.sizes[ size ]; 2172 } 2173 } ); 2167 2174 2168 2175 this.params.attachment = attachment; … … 2170 2177 // Set the Customizer setting; the callback takes care of rendering. 2171 2178 this.setting( attachment.id ); 2172 2173 2179 2174 2180 // Update the icon in-browser.
Note: See TracChangeset
for help on using the changeset viewer.