Opened 10 years ago
Closed 10 years ago
#37118 closed enhancement (fixed)
Move call of get_blog_details() inside of ms_site_check()
| Reported by: | danielbachhuber | Owned by: | jeremyfelt |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.6 |
| Component: | Bootstrap/Load | Version: | |
| Severity: | normal | Keywords: | has-patch commit |
| Cc: | Focuses: | multisite |
Description
get_blog_details() is unnecessarily called at the top of ms_site_check(). It should be called when the blog's details are actually needed.
When a non-web context is bypassing ms_site_check() using the ms_site_check filter, the call to get_blog_details() causes a MySQL error notice when WordPress isn't yet installed.
Related #34936
From https://github.com/wp-cli/wp-cli/issues/2278#issuecomment-226634504
Attachments (1)
Change History (5)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
+1
Noting #36935 for cross-reference. We'll be able to replace this with
get_site()at some point, but the move is good either way.