Opened 10 years ago
Closed 10 years ago
#38152 closed defect (bug) (fixed)
Clarify in the DocBlock that get_site_by_path() does not return exact matches
| Reported by: | ocean90 | Owned by: | jeremyfelt |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.7 |
| Component: | Networks and Sites | Version: | |
| Severity: | normal | Keywords: | good-first-bug has-patch |
| Cc: | Focuses: | docs, multisite |
Description
Related Slack discussion: https://wordpress.slack.com/archives/core-multisite/p1474390310000390
get_site_by_path() does not return exact matches because it also searches sites with path = '/'. The same applies to WP_Network::get_by_path() but its DocBlock is much better. We should add a similar comment to get_site_by_path().
Attachments (2)
Change History (10)
This ticket was mentioned in Slack in #docs by morganestes. View the logs.
10 years ago
#5
@
10 years ago
sry., there was a diff option issue. In the previous patch, the red block should be the green block and vice versa.
I've uploaded a revised version.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
The patch doesn't seem to match the description. Don't we want the description to be more descriptive, rather than shorter here?