diff --git a/changelog.md b/changelog.md index c2d0b04..f866eb5 100644 --- a/changelog.md +++ b/changelog.md @@ -35,8 +35,16 @@ Minor update to: * Update to index extension call to more logical naming * Minor tweak to account summary template +# 1.2.1 + +* Add additional extension hooks when edit form submitted + # 2.0.0 * SS4 support based on version 1.1.1 * Update to index extension call to more logical naming -* Minor tweak to account summary template \ No newline at end of file +* Minor tweak to account summary template + +# 2.0.1 + +* Add additional extension hooks when edit form submitted \ No newline at end of file diff --git a/src/forms/EditAccountForm.php b/src/forms/EditAccountForm.php index e1952ab..8221794 100755 --- a/src/forms/EditAccountForm.php +++ b/src/forms/EditAccountForm.php @@ -81,6 +81,8 @@ public function doUpdate($data) $member = Member::get()->byID($data["ID"]); $curr = Security::getCurrentUser(); + $this->extend("onBeforeUpdate", $data); + // Check that a member isn't trying to mess up another users profile if (!empty($curr) && $member->canEdit($curr)) { // Save member @@ -98,8 +100,10 @@ public function doUpdate($data) ); } + $this->extend("onAfterUpdate", $data); + return $this ->getController() ->redirectBack(); } -} +} \ No newline at end of file