Opened 7 weeks ago
Last modified 6 weeks ago
#63518 new defect (bug)
get_blog_details( get_all: false ) not working as expected
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | |
Component: | Networks and Sites | Keywords: | has-patch changes-requested reporter-feedback |
Focuses: | multisite | Cc: |
Description
I recently played around with get_blog_details()
and found that the second parameter is not as expected.
<?php get_blog_details( 1, true ); // will return the long results. get_blog_details( 1, false ); // will also return the long results. get_blog_details( 2, false ); // will return the short results. get_blog_details( 2, true ); // will return the long results. get_blog_details( 2, false ); // will still return the short results.
So if you call it with $get_all = false
first, it works as expected and it seems to cache the short result separately and you can call them in any order and how often you want.
If you call $get_all = true
first, it will ignore the second parameter and will always return the long results.
It seems to me like the caching in the function is not working properly.
Attachments (1)
Change History (7)
#2
@
6 weeks ago
Hey @immeet94 thank you for the patch.
I tried to apply your patch and test it, but I could not find where to apply your patch, checked with 6.8.1 and trunk.
Could you verify your patch?
Greetings from WCEU2025
#3
@
6 weeks ago
Reproduction Report
Description
This report validates whether the issue can be reproduced.
Environment
- WordPress: 6.8.1
- PHP: 8.2.23
- Server: nginx/1.26.1
- Database: mysqli (Server: 8.0.35 / Client: mysqlnd 8.2.23)
- Browser: Chrome 137.0.0.0
- OS: Windows 10/11
- Theme: Twenty Twenty-Five 1.2
- MU Plugins: None activated
- Plugins:
- Test Reports 1.2.0
Actual Results
- ❌ Error condition not occurs (not reproduced).
Additional Notes
- To reproduce the issue, I printed the result returned by
get_blog_details()
as suggested by @apermo . It appears to be working as expected upon inspection. I couldn’t find any issue.
Supplemental Artifacts
Screenshot: https://prnt.sc/ipp9hsBdXHWT
Hey @apermo
Thanks for created ticket and i created patch for that, please review and test it.let me know for query.
Thanks