function botcha_update_6201 in BOTCHA Spam Prevention 6.3
Same name and namespace in other branches
- 6.2 botcha.install \botcha_update_6201()
Create an interface to manage the list of forms that are forbidden to protect.
1 call to botcha_update_6201()
- botcha_install in ./
botcha.install - Implementation of hook_install().
File
- ./
botcha.install, line 420
Code
function botcha_update_6201() {
$ret = array();
foreach (_botcha_default_form_ids() as $form_id) {
$enabled = !in_array($form_id, array(
'update_script_selection_form',
'user_login',
'user_login_block',
));
// @todo Find a way to use usual application interface to perform even update changes.
//Botcha::getForm($form_id, TRUE)->setEnabled($enabled)->save();
// Cast to boolean first.
$enabled = (bool) $enabled;
// Cast to integer.
$enabled = (int) $enabled;
variable_set("botcha_enabled_{$form_id}", $enabled);
}
return $ret;
}