Hi, everything were ok on my website but know when I try to create a new user I get this error :

Fatal error: Unsupported operand types in /var/domains/xxx/domains/xxx/www/includes/form.inc on line 1237

The lines code in this file are

function form_type_select_value($form, $edit = FALSE) {
  if ($edit !== FALSE) {
    if (isset($form['#multiple']) && $form['#multiple']) {
       return (is_array($edit)) ? drupal_map_assoc($edit) : array(); // line 1237
    }
    else {
      return $edit;
    }
  }
}

I don't know what is this error and how to fix it.

Any ideas ?

Comments

jnov’s picture

Oups, good lines are :

function form_type_password_confirm_value($form, $edit = FALSE) {
  if ($edit === FALSE) {
    $form += array('#default_value' => array());
    return $form['#default_value'] + array('pass1' => '', 'pass2' => ''); // this line is 1237
  }
}
jnov’s picture

Status: Active » Closed (fixed)

OK fixed

replace
function form_type_password_confirm_value($form, $edit = FALSE) {
by
function form_type_password_confirm_default_value($form, $edit = FALSE) {