Needs review
Project:
Uniqueness
Version:
6.x-1.0-rc1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
20 Oct 2011 at 19:41 UTC
Updated:
21 Oct 2011 at 13:43 UTC
Jump to comment: Most recent file
Comments
Comment #1
kndrHere is the patch. Some pieces of code are moved to after_build functions. There is also additional check to prevent Drupal.settings from being added twice during validation phase.
Comment #2
bforchhammer commentedSorry, I can't reproduce your problem. When I add a required CCK field and force a validation error, I still do get the "related content" widget, prefilled with nodes matching the current title... Could you provide a more detailed description of your problem?
Comment #3
kndrHm. Did you test it inside a block? I use uniqueness widget as a block and it disappears when errors are shown. I didn't test it on pure Drupal installation. I use Panels and I've put widget as a block inside 'node edit/add' page. Widget is connected with Apache Solr. I use Pressflow, too.
Comment #4
kndrI've done quick search about problem with javascipt and hook_form_alter. Look, for example, at #908910: JS/CSS files not loading after a validation error. You will see, that problem is resolved by #after_build callback.