function notifications_access_subscribe in Notifications 7
Same name and namespace in other branches
- 6.4 notifications.module \notifications_access_subscribe()
- 6 notifications.module \notifications_access_subscribe()
- 6.2 notifications.module \notifications_access_subscribe()
- 6.3 notifications.module \notifications_access_subscribe()
Menu access callback for subscribe links.
More access checking depending on subscription type will be done at the destination page
1 string reference to 'notifications_access_subscribe'
- notifications_menu in ./
notifications.module - Implementation of hook_menu().
File
- ./
notifications.module, line 258 - Notifications module
Code
function notifications_access_subscribe($substype, $account = NULL) {
if ($substype && notifications_subscription_type_enabled($substype->type)) {
$account = $account ? $account : $GLOBALS['user'];
if ($account->uid) {
return user_access('create subscriptions', $account);
}
elseif (notifications_check_signature()) {
return TRUE;
// Signed link
}
}
}