[wp-trac] [WordPress Trac] #57114: Add caching to is_block_theme
WordPress Trac
noreply at wordpress.org
Tue Nov 15 12:12:32 UTC 2022
#57114: Add caching to is_block_theme
--------------------------+--------------------
Reporter: spacedmonkey | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: 6.2
Component: Themes | Version: 5.9
Severity: normal | Keywords:
Focuses: performance |
--------------------------+--------------------
The function `is_block_theme` does a check on the filesystem if some times
existing. This function could be called 100 of times per page request
which would result in many many lookups. This value does not change,
unless a theme is upgraded. Added a check would be simple and would save
some CPU resources in looking up files.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/57114>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list