Fixing PHP notice caused by WordPress 3.9 update / Multisite performance updates#33
Merged
Conversation
…in WordPress 3.9.
…r hosts, and caches the array of hosts after it runs the first time. Actual code changes are at line 49, and lines 136-153.
Author
|
After implementing my changes for multisite performance, a site that was running an average of 1500 queries @ 246ms average dropped significantly (90% drop in queries -160 average, 81% drop in speed - 90ms average). |
Conflicts: lib/WordPressHTTPS.php
Author
|
Refreshed my commit so it will merge without conflicts. Also, it appears that other pull requests (#32) fixed the warnings that my patch fixed, so only included my performance fixes. |
headstash
added a commit
that referenced
this pull request
Oct 15, 2015
Fixing PHP notice caused by WordPress 3.9 update / Multisite performance updates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Since WordPress 3.9, $wpdb::prepare requires at least one placeholder. The current line of code causes the following error:
This is an error that will only effect multisite installs.
This pull fixes the notice, which appears hundreds of times per page load, causing a massive debug.log. Since we are not taking any input, we don't really need to prepare the query anyways.