Opened 9 years ago
Closed 9 years ago
#6721 closed enhancement (fixed)
Remove PHP4 Constructor backcompat method from BP_Groups_Widget class
Reported by: | tw2113 | Owned by: | boonebgorges |
---|---|---|---|
Milestone: | 2.5 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Groups | Keywords: | good-first-bug needs-patch commit |
Cc: | brajesh@… |
Description
Not sure we need this any more.
/** * PHP4 constructor * * For backward compatibility only */ function bp_groups_widget() { $this->_construct(); }
Plus not seeing the _construct() method in the class anyway.
Attachments (1)
Change History (10)
#1
@
9 years ago
- Component changed from API to Component - Groups
- Keywords needs-patch added
- Milestone changed from Awaiting Review to 2.5
#2
@
9 years ago
Not arguing at all, but does it end up matching up with the single underscore vs double underscore? May be learning something new here myself.
#3
@
9 years ago
Ah, I didn't notice the single underscore. https://buddypress.trac.wordpress.org/changeset/4211 I'm not sure whether WP required PHP 5 at this time - if so, the groups widget would've thrown a fatal error on PHP4. So yeah, let's rip it out.
Easy props for a first-time contributor.
#4
@
9 years ago
- Cc brajesh@… added
It has been 8 weeks without any new patch, so here I am putting one.
The patch removes php4 style constructor and also cleans up the code to follow WP Coding standards.
https://buddypress.trac.wordpress.org/browser/trunk/src/bp-groups/bp-groups-widgets.php?marks=21-32#L20
But yes, we can remove the PHP4 constructor.