When installing multiple features as part of an install profile I've found that later features can't depend on node types provided.

Specifically, importing nodes using node_export fails for one of my node types as node_type_get_name() returned false.

The attached patch adds a call to node_types_rebuild() when enabling a feature that provides new node types.

Comments

jacktonkin’s picture

StatusFileSize
new1.06 KB
hefox’s picture

Status: Needs review » Needs work

Haven't reviewed, but doesn't pass coding standards from a quick review -- else needs to be
}
else

Thanks for the patch

mpotter’s picture

Status: Needs work » Fixed

Committed this along with the coder change from #2 to df1726a.

  • mpotter committed df1726a on 7.x-2.x authored by jacktonkin
    Issue #2510352 by jacktonkin: Call node_types_rebuild() when providing...

Status: Fixed » Closed (fixed)

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

taran2l’s picture

Thanks! Fixes very annoying issue.

Could you take a look at #2143765: features_modules_enabled() doesn't work when features_load_feature cache doesn't include the feature. Similar issue, but with taxonomies.