Просмотр исходного кода

Merge pull request #314 from Automattic/independent-publisher-2-add-gutenberg-support

Independent Publisher 2: Correct JavaScript error
Laurel 6 лет назад
Родитель
Сommit
ac5250811f
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      independent-publisher-2/js/independent-publisher-2.js

+ 1 - 1
independent-publisher-2/js/independent-publisher-2.js

@@ -32,7 +32,7 @@
 
 
                     if ( img_width >= 1100
                     if ( img_width >= 1100
                         && img.parents( '.tiled-gallery-item-large' ).length === 0
                         && img.parents( '.tiled-gallery-item-large' ).length === 0
-                        && img.parents().attr( ['class^="wp-block-"'] ).length === 0 ) {
+                        && img.parents( '[class^="wp-block-"]' ).length === 0 ) {
                             $( img ).addClass( 'size-big' );
                             $( img ).addClass( 'size-big' );
                      }
                      }