summaryrefslogtreecommitdiff
path: root/modules/user/user.module
diff options
context:
space:
mode:
Diffstat (limited to 'modules/user/user.module')
-rw-r--r--modules/user/user.module29
1 files changed, 27 insertions, 2 deletions
diff --git a/modules/user/user.module b/modules/user/user.module
index 90d313b10..84430b2f7 100644
--- a/modules/user/user.module
+++ b/modules/user/user.module
@@ -2266,7 +2266,18 @@ function user_pass_reset_url($account) {
}
/**
- * Generate a URL to confirm an account cancellation request.
+ * Generates a URL to confirm an account cancellation request.
+ *
+ * @param object $account
+ * The user account object, which must contain at least the following
+ * properties:
+ * - uid: The user uid number.
+ * - pass: The hashed user password string.
+ * - login: The user login name.
+ *
+ * @return
+ * A unique URL that may be used to confirm the cancellation of the user
+ * account.
*
* @see user_mail_tokens()
* @see user_cancel_confirm()
@@ -2698,7 +2709,21 @@ Your account on [site:name] has been canceled.
/**
* Token callback to add unsafe tokens for user mails.
*
- * @see user_mail()
+ * This function is used by the token_replace() call at the end of
+ * _user_mail_text() to set up some additional tokens that can be
+ * used in email messages generated by user_mail().
+ *
+ * @param $replacements
+ * An associative array variable containing mappings from token names to
+ * values (for use with strtr()).
+ * @param $data
+ * An associative array of token replacement values. If the 'user' element
+ * exists, it must contain a user account object with the following
+ * properties:
+ * - login: The account login name.
+ * - pass: The hashed account login password.
+ * @param $options
+ * Unused parameter required by the token_replace() function.
*/
function user_mail_tokens(&$replacements, $data, $options) {
if (isset($data['user'])) {