Automattic / babble

Multilingual WordPress done right.
https://wordpress.org/plugins/babble/
246 stars 50 forks source link

Don't use `& $this` #169

Closed rmccue closed 10 years ago

rmccue commented 10 years ago

From PHP 5 onwards, all objects are passed by reference, so & $this is redundant. This is a common pattern with add_action/add_filter calls (since the callback is an array), but should just the bare $this instead.

tomjn commented 10 years ago

Agreed, are you referring more to this:

https://github.com/cftp/babble/blob/master/class-plugin.php#L208

simonwheatley commented 10 years ago

I will happily merge a pull request which removes these ;)

markoheijnen commented 10 years ago

Note that #172 makes a change that will create a merge conflict.