[wp-trac] [WordPress Trac] #54326: `username_exists()` is passed a blog name in wp-includes/ms-functions.php
WordPress Trac
noreply at wordpress.org
Tue Oct 26 23:08:34 UTC 2021
#54326: `username_exists()` is passed a blog name in wp-includes/ms-functions.php
--------------------------+------------------------------
Reporter: henry.wright | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
--------------------------+------------------------------
Comment (by henry.wright):
> I don't think such a comment like in 54326.diff​ adds much value
I disagree. The function call in the next line isn't used to check if a
username exists. It is used in a different way. Because the function name
is username_exists(), a comment is absolutely necessary in my opinion. A
comment in the DockBlock for the wpmu_validate_blog_signup() function
isn't the best place.
If username_exists() was named
username_exists_or_blogname_matches_existing_username() we wouldn't need
the inline comment :D
--
Ticket URL: <https://core.trac.wordpress.org/ticket/54326#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list