[wp-trac] [WordPress Trac] #36982: Add image attributes and additional context to the wp_calculate_image_srcset and wp_calculate_image_sizes filters

WordPress Trac noreply at wordpress.org
Tue Feb 2 06:30:58 UTC 2021


#36982: Add image attributes and additional context to the
wp_calculate_image_srcset and wp_calculate_image_sizes filters
-------------------------------------------------+-------------------------
 Reporter:  kylereicks                           |       Owner:
                                                 |  adamsilverstein
     Type:  enhancement                          |      Status:  assigned
 Priority:  normal                               |   Milestone:  5.7
Component:  Media                                |     Version:  4.6
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch 2nd-opinion has-unit-      |     Focuses:  template
  tests                                          |
-------------------------------------------------+-------------------------

Comment (by antpb):

 Just investigating the first failure around the `get_custom_logo()`
 `1) Tests_WP_Customize_Manager::test_import_theme_starter_content
 Undefined variable: image_attr`

 I tested the function on a fresh install with a custom logo set and am
 seeing errors when using the function.

 Getting the notice
 `Notice: Undefined variable: image_attr in /var/www/src/wp-
 includes/media.php on line 1529`

 I need to dig deeper into the other ~50 failures to see if theres another
 function we'll need to factor this fix into. Likely a repeated function
 through our tests. `get_custom_logo` doesnt seem to be more than a 5 of
 them.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/36982#comment:27>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list