wordpress-develop/tests
Jonny Harris 0c7ddbd67a Options, Meta APIs: Optimize get_option by relocating notoptions cache lookup.
In the get_option function, a cache lookup for the notoptions key is performed, which stores an array of keys for options known not to exist. This optimization prevents repeated database queries when certain options are requested. However, the cache lookup for notoptions was conducted before checking if the requested option exists in the cache. Given that it's more likely that the option does exist, this commit reorders the checks to first verify the option's existence in the cache before confirming its absence. This adjustment reduces redundant queries and also eliminates an unnecessary cache lookup, improving overall performance.

Props spacedmonkey, costdev, flixos90, azaozz.
Fixes #58277.

git-svn-id: https://develop.svn.wordpress.org/trunk@56595 602fd350-edb4-49c9-b593-d223f7449a82
2023-09-15 16:13:52 +00:00
..
e2e Build/Test Tools: Prevent 404 errors in the E2E tests. 2023-07-11 03:39:39 +00:00
gutenberg Block Editor: Update the Gutenberg branch used to launch Gutenberg e2e tests. 2021-06-01 09:21:36 +00:00
performance Coding Standards: Include one space after function keyword for closures. 2023-09-12 15:21:02 +00:00
phpunit Options, Meta APIs: Optimize get_option by relocating notoptions cache lookup. 2023-09-15 16:13:52 +00:00
qunit Editor: load title on navigation fallback. 2023-07-25 06:28:28 +00:00
visual-regression Build/Test Tools: Update some NPM dependencies to the latest versions. 2022-04-08 20:05:03 +00:00