function eu_cookie_compliance_update_7009 in EU Cookie Compliance (GDPR Compliance) 7
Same name and namespace in other branches
- 7.2 eu_cookie_compliance.install \eu_cookie_compliance_update_7009()
Disable withdraw tab and banner in the consent method "Consent by default".
File
- ./
eu_cookie_compliance.install, line 445 - Installation file.
Code
function eu_cookie_compliance_update_7009() {
$eu_cookie_settings = variable_get('eu_cookie_compliance', array());
if (!empty($eu_cookie_settings['method']) && $eu_cookie_settings['method'] === 'default' && !empty($eu_cookie_settings['withdraw_enabled']) && $eu_cookie_settings['withdraw_enabled'] == 1) {
$eu_cookie_settings['withdraw_enabled'] = 0;
}
variable_set('eu_cookie_compliance', $eu_cookie_settings);
}