[wp-trac] [WordPress Trac] #51015: has_custom_logo isn't working with Customizer
WordPress Trac
noreply at wordpress.org
Tue Aug 18 15:17:38 UTC 2020
#51015: has_custom_logo isn't working with Customizer
-------------------------------+------------------------------
Reporter: athemeart | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Customize | Version: 5.5
Severity: normal | Resolution:
Keywords: reporter-feedback | Focuses:
-------------------------------+------------------------------
Comment (by sabernhardt):
I was able to reproduce with these steps:
1. Add the `has_custom_logo` conditional code to the theme template file
(likely header.php).
2. Open Customizer.
3. Set an image as the logo.
4. Click Publish and refresh the page.
5. Then remove the logo image.
6. **Before** publishing and refreshing the page, check results.
The blog name should show after removing the logo. However,
`the_custom_logo` still runs and gives the hidden linked image
placeholder, even though `has_custom_logo` should return false. It does
seem to work correctly after publishing and refreshing the page.
Note also: the function `the_custom_logo` does not need `echo` (`echo` is
already part of it).
--
Ticket URL: <https://core.trac.wordpress.org/ticket/51015#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list