diff options
author | Andreas Gohr <andi@splitbrain.org> | 2013-01-26 11:21:39 +0100 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2013-01-26 11:21:39 +0100 |
commit | ba56222349781fd8e3938ab18127d46f3c1e0061 (patch) | |
tree | 1e39e4e2960462ea06ae55a993512bf18ce4aa25 /inc/auth.php | |
parent | 1285aa3a44c9fdf49bfd8992f33bac068bae8226 (diff) | |
parent | c38b7fab9eeb9456aaf5fe8e4481c3b8569e5644 (diff) | |
download | rpg-ba56222349781fd8e3938ab18127d46f3c1e0061.tar.gz rpg-ba56222349781fd8e3938ab18127d46f3c1e0061.tar.bz2 |
Merge branch 'subscription' Pull Request #125
* subscription: (25 commits)
link directly to subscription management in mails
only use mailfromnobody for bulk mails
added missing context for list mails
readded mailfromnobody to subscription sending
correctly escape diffs in HTML mails
fixed lists in HTML mails
simplified subscription->add() code a bit
comment adjusted
removed unused vars
removed data parameter in subscription_handle_post()
fixed tests
some reformatting
added compatibility function
moved registration notification to subscription class
fixed merge error in inc/auth.php
consolidate more notification code in subscription class
minor cleanup
initialize new subscriptions with current time
fixed subscription management
correctly check if subscriptions are enabled
...
Diffstat (limited to 'inc/auth.php')
-rw-r--r-- | inc/auth.php | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/inc/auth.php b/inc/auth.php index c68a699fe..c4f1dcf2b 100644 --- a/inc/auth.php +++ b/inc/auth.php @@ -780,23 +780,19 @@ function register() { return false; } - // create substitutions for use in notification email - $substitutions = array( - 'NEWUSER' => $login, - 'NEWNAME' => $fullname, - 'NEWEMAIL' => $email, - ); + // send notification about the new user + $subscription = new Subscription(); + $subscription->send_register($login, $fullname, $email); + // are we done? if(!$conf['autopasswd']) { msg($lang['regsuccess2'], 1); - notify('', 'register', '', $login, false, $substitutions); return true; } - // autogenerated password? then send him the password + // autogenerated password? then send password to user if(auth_sendPassword($login, $pass)) { msg($lang['regsuccess'], 1); - notify('', 'register', '', $login, false, $substitutions); return true; } else { msg($lang['regmailfail'], -1); |