You are here

function _widgets_error in Widgets 7

2 calls to _widgets_error()
widgets_get_error in ./widgets.module
widgets_set_error in ./widgets.module

File

./widgets.module, line 1038
Exposes global functionality for creating widget sets.

Code

function _widgets_error($name, $action = 'get') {
  static $errors = array();
  if ($action == 'set') {
    $errors[$name] = TRUE;
  }
  elseif ($action == 'reset') {
    $errors[$name] = FALSE;
  }
  if (isset($errors[$name])) {
    return $errors[$name];
  }
  else {
    return FALSE;
  }
}