File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414
1515( ( ) => {
1616 // Create placeholder so content doesn't jump around as noticably
17- const lastModifiedElement = createLastModifiedElement ( 'Date: checking...' ) ;
17+ const lastModifiedElement = createLastModifiedElement ( " " ) ;
1818 const productDescription = getProductDescription ( ) ;
1919 productDescription . prepend ( lastModifiedElement ) ;
2020
2121 const url_main = getMainProductImageUrl ( ) ;
2222 const url_thumbs = getOtherProductImageUrls ( ) ;
2323
24- const oldestUrlDate = promiseOldestUrlDate ( [ url_main , ...url_thumbs ] ) ;
25-
26- oldestUrlDate . then ( date => {
27- if ( ! date ) return ;
28-
29- const fuzzy = getFuzzyDateFormat ( date ) ;
30- lastModifiedElement . firstChild . innerHTML = `Date: ${ fuzzy } ` ;
24+ promiseOldestUrlDate ( [ url_main , ...url_thumbs ] ) . then ( date => {
25+ if ( date ) {
26+ const fuzzy = getFuzzyDateFormat ( date ) ;
27+ lastModifiedElement . firstChild . innerHTML = `Date: ${ fuzzy } ` ;
28+ }
3129 } ) ;
3230} ) ( ) ;
3331
You can’t perform that action at this time.
0 commit comments