[wp-trac] [WordPress Trac] #52183: get_the_post_thumbnail_url function returns original url if the size didnt exist
    WordPress Trac 
    noreply at wordpress.org
       
    Mon Dec 28 09:04:17 UTC 2020
    
    
  
#52183: get_the_post_thumbnail_url  function returns original url if the size didnt
exist
--------------------------+-----------------------------
 Reporter:  naveen17797   |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  5.6
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 From the function description it should return false if the size does not
 exist.
 Steps to replicate the issue
 1. I uploaded a image via featured image field on the post edit screen.
 2. I am calling this function inside the theme file like this
 $medium_thumbnail_url = get_the_post_thumbnail_url( $post_id, 'medium');
 But this function returns original url instead of returning false.
-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/52183>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
    
    
More information about the wp-trac
mailing list