26 lines
654 B
Plaintext
26 lines
654 B
Plaintext
<?php
|
|
|
|
|
|
/**
|
|
* Implement hook_user()
|
|
*
|
|
*/
|
|
function materio_user_rules_user_update(&$edit, $account) {
|
|
if (!empty($account->logintoboggan_email_validated)) {
|
|
$subscritpions = ;
|
|
rules_invoke_event('materio_logintoboggan_validated', $account, $subscritpions);
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Implements hook_simplenews_unsubscribe_user().
|
|
*/
|
|
function materio_user_rules_simplenews_subscribe_user($subscriber, $subscription) {
|
|
if (!empty($subscriber->logintoboggan_email_validated)) {
|
|
$args = array(
|
|
'mail' => $subscriber->mail,
|
|
'tid' => $subscription->tid,
|
|
);
|
|
rules_invoke_event_by_args('simplenews_rules_event_subscribe', $args);
|
|
}
|
|
} |