function genpass_algorithm_module in Generate Password 7
Same name and namespace in other branches
- 8 genpass.module \genpass_algorithm_module()
- 6 genpass.module \genpass_algorithm_module()
Return the currently activated module for generating passwords. Does some validation to make sure the variable contains a valid module name.
Return value
the name of the module whose implementation of hook_password is currently the preferred implementation.
2 calls to genpass_algorithm_module()
- genpass_form_alter in ./
genpass.module - Implementation of hook_form_alter()
- genpass_generate in ./
genpass.module - Generate a new password using the preferred password generation algorithm.
File
- ./
genpass.module, line 264
Code
function genpass_algorithm_module() {
$modules = genpass_algorithm_modules();
$module = variable_get('genpass_algorithm', 'genpass');
if (in_array($module, array_keys($modules))) {
return $module;
}
else {
return 'genpass';
}
}