By replacing

if (!isset($form_state['storage']['hs']['js_settings_sent'][$hsid]) ){

with

if (!isset($form_state['storage']['hs']['js_settings_sent'][$hsid]) || (isset($form_state['storage']['hs']['js_settings_sent'][$hsid]) && (isset($form_state['triggering_element']) && $form_state['triggering_element']['#type'] == 'submit'))) {

on line 411 of hierarchical_select.module I am able to get it working.

I realise this is a pretty dirty has so I thought someone who knows the module better would be able to come up with a better solution

Comments

stefan.r’s picture

Issue summary: View changes
Status: Active » Fixed

  • stefan.r committed 0f3e690 on 7.x-3.x
    Issue #1271192: JS not initialized if form fails validation
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.