Change args in `after_signup_user` action
|Reported by:||MaximeCulea||Owned by:||SergeyBiryukov|
In 4.4.0 WP's version, 34112's ticket has been merged, including after_signup_user's action. The phpdoc is saying that $meta is an array :
* @param array $meta Additional signup meta. By default, this is an empty array.
It's not really true, because just before, l.723, we can find this : $meta = serialize($meta);
So or we update the phpdoc, saying it's a string (serialized array), or we change this 4th args' format.
This last option it's my favorite one, that's why I am proposing to change after_signup_user's action's 4th args from $meta into unserialize( $meta ), according to the phpdoc, which I agree with. It's much easier to use data which is already unserialized !
In fact for efficiency purpose, I prefer not to overwrite $meta value with serialized one, as l.723, but directly doing it inside wpdb->insert() args. This way, the $meta variable is not serialized and can be passed as it to after_signup_user's action's args.
By changing this behaviour, we could also fix how wpmu_signup_user_notification's method use given $meta.
Change History (10)
- Owner set to SergeyBiryukov
- Resolution set to fixed
- Status changed from new to closed