summaryrefslogtreecommitdiff
path: root/plugins/OpenID/finishaddopenid.php
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-05-20 12:21:29 -0700
committerBrion Vibber <brion@pobox.com>2010-05-25 17:11:46 -0700
commit9193c110f14e09523791683e7799a45163b881c2 (patch)
treed5b9462008438aaf1b178870f6987034590761a4 /plugins/OpenID/finishaddopenid.php
parentd9a89d174ad1cb28669a8f3c76be23f27c182d58 (diff)
WikiHowProfile plugin; pulls avatar from WikiHow profile pages when registering or adding account with OpenID. (Full name, location, homepage, and bio are also on the profile page but not marked up in a way they can be easily retrieved yet.)
OpenID plugin: Added events at OpenID account creation and update time to allow additional customizations for particular sites.
Diffstat (limited to 'plugins/OpenID/finishaddopenid.php')
-rw-r--r--plugins/OpenID/finishaddopenid.php11
1 files changed, 7 insertions, 4 deletions
diff --git a/plugins/OpenID/finishaddopenid.php b/plugins/OpenID/finishaddopenid.php
index 991e6584e..18e150a83 100644
--- a/plugins/OpenID/finishaddopenid.php
+++ b/plugins/OpenID/finishaddopenid.php
@@ -126,12 +126,15 @@ class FinishaddopenidAction extends Action
$this->message(_m('Error connecting user.'));
return;
}
- if ($sreg) {
- if (!oid_update_user($cur, $sreg)) {
- $this->message(_m('Error updating profile'));
- return;
+ if (Event::handle('StartOpenIDUpdateUser', array($cur, $canonical, &$sreg))) {
+ if ($sreg) {
+ if (!oid_update_user($cur, $sreg)) {
+ $this->message(_m('Error updating profile'));
+ return;
+ }
}
}
+ Event::handle('EndOpenIDUpdateUser', array($cur, $canonical, $sreg));
// success!