diff options
author | Dries Buytaert <dries@buytaert.net> | 2009-08-12 12:36:05 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2009-08-12 12:36:05 +0000 |
commit | 06fbe8e90ce3272b4879dc967b95bd6937875dc8 (patch) | |
tree | 559bc0e8ea44793dab12ecf446ebccb379f40fff /modules/contact | |
parent | a83e5605c763ddb2995cbec002576f29d75a9402 (diff) | |
download | brdo-06fbe8e90ce3272b4879dc967b95bd6937875dc8.tar.gz brdo-06fbe8e90ce3272b4879dc967b95bd6937875dc8.tar.bz2 |
- Patch #491972 by Berdir, webchick: clean-up of user/profile related hooks and APIs.
Diffstat (limited to 'modules/contact')
-rw-r--r-- | modules/contact/contact.module | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/modules/contact/contact.module b/modules/contact/contact.module index 1cbbec704..7ee6936d0 100644 --- a/modules/contact/contact.module +++ b/modules/contact/contact.module @@ -138,7 +138,7 @@ function contact_load($cid) { /** * Implement hook_user_form(). */ -function contact_user_form(&$edit, &$user, $category = NULL) { +function contact_user_form(&$edit, $account, $category) { if ($category == 'account') { $form['contact'] = array('#type' => 'fieldset', '#title' => t('Contact settings'), @@ -148,7 +148,7 @@ function contact_user_form(&$edit, &$user, $category = NULL) { $form['contact']['contact'] = array('#type' => 'checkbox', '#title' => t('Personal contact form'), '#default_value' => !empty($edit['contact']) ? $edit['contact'] : FALSE, - '#description' => t('Allow other users to contact you via a <a href="@url">personal contact form</a> which keeps your e-mail address hidden. Note that some privileged users such as site administrators are still able to contact you even if you choose to disable this feature.', array('@url' => url("user/$user->uid/contact"))), + '#description' => t('Allow other users to contact you via a <a href="@url">personal contact form</a> which keeps your e-mail address hidden. Note that some privileged users such as site administrators are still able to contact you even if you choose to disable this feature.', array('@url' => url("user/$account->uid/contact"))), ); return $form; } @@ -157,18 +157,11 @@ function contact_user_form(&$edit, &$user, $category = NULL) { /** * Implement hook_user_insert(). */ -function contact_user_insert(&$edit, &$user, $category = NULL) { +function contact_user_insert(&$edit, $account, $category) { $edit['contact'] = variable_get('contact_default_status', 1); } /** - * Implement hook_user_validate(). - */ -function contact_user_validate(&$edit, &$user, $category = NULL) { - return array('contact' => isset($edit['contact']) ? $edit['contact'] : FALSE); -} - -/** * Implement hook_mail(). */ function contact_mail($key, &$message, $params) { |