function drupalgap_logintoboggan_services_resources_alter in DrupalGap 7
Same name and namespace in other branches
- 7.2 modules/drupalgap_logintoboggan/drupalgap_logintoboggan.module \drupalgap_logintoboggan_services_resources_alter()
Implements hook_services_resources_alter().
File
- modules/
drupalgap_logintoboggan/ drupalgap_logintoboggan.module, line 15
Code
function drupalgap_logintoboggan_services_resources_alter(&$resources, &$endpoint) {
// Override the normal user login callback.
if (variable_get('logintoboggan_login_with_email', 0) == 1 && isset($resources['user']['actions']['login']['callback'])) {
$resources['user']['actions']['login']['callback'] = 'drupalgap_logintoboggan_services_login';
}
}