In inline_form_alter(), the variable_get() call is dependent on the $node_type, which is specified to come from $form['orig_type']['#value']. However, on several node forms that form value is empty (for what reason I'm not entirely certain). That results in the variable_get() call always returning false/0, so that form field always defaults to "Disabled".

Comments

sun’s picture

Status: Active » Needs review
StatusFileSize
new1.68 KB
new1.05 KB

You've successfully identified some cruft code from 4.7.x good ol' times.

Attached patch fixes this by implementing the same logic like Comment module in core. However, that logic is plain wrong and still a bug in Drupal 7.x, because $form['identity']['type'] is always set in the content-type form and I guess it should be !empty($form['identity']['type']['#default_value']) or similar, to prevent those fields from showing up on content-type creation forms and hence, prevent storing 'module_node_' variables.

sun’s picture

Any updates? Anyone able to test whether this patch does NOT break existing sites/configurations?