#5755 closed defect (bug) (fixed)
xprofile_updated_profile action not properly passed old values
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.1 | Priority: | normal |
Severity: | normal | Version: | 2.0 |
Component: | Extended Profile | Keywords: | |
Cc: |
Description ¶
The function xprofile_screen_edit_profile()
updates profile fields and has $new_values
and $old_values
variables which are passed to the xprofile_updated_profile
action. This action is useful for monitoring when profile fields are updated.
The problem is that $old_values
is called after the value is updated via xprofile_set_field_data()
. This means that $old_values
will always contain the new values.
The attached patch (my first BP one!) resolves the issue in my limited testing. It moves the $old_values
definition to before the field is updated.
Commits (3)
- [8630] xProfile: when a user's profile is updated, correctly pass the fields' previous values to the
xprofile_updated_profile
action.… by @djpaul 11 years ago - [8631] xProfile: when updating a user profile, make sure the actions are passed the field's current (new) value.… by @djpaul 11 years ago
- [8691] xProfile: when a user's profile is updated, correctly pass the fields' previous values to the
xprofile_updated_profile
action.… by @djpaul 11 years ago
Pull Requests
- Loading…
Change History (6)
#4
@
11 years ago
Thanks for the patch, Viper007Bond, and congrats on your first BuddyPress props. :)
In 8630: