You are here

function webform_update_7406 in Webform 7.4

Convert the "webform_use_cookies" setting to "webform_tracking_mode".

File

./webform.install, line 1700
Webform module install/schema hooks.

Code

function webform_update_7406() {

  // Previously, we only had "strict" and "ip_address" checking. Using cookies
  // meant cookies in addition to IP address.
  $use_cookies = variable_get('webform_use_cookies');
  if (isset($use_cookies)) {
    variable_set('webform_tracking_mode', $use_cookies ? 'strict' : 'ip_address');
    variable_del('webform_use_cookies');
  }
}