function ctools_content_prepare_subtype
Ensure minimal required settings on a content subtype exist.
2 calls to ctools_content_prepare_subtype()
- ctools_content_get_subtype in includes/
content.inc - Given a content type and a subtype id, return the information about that content subtype.
- ctools_content_get_subtypes in includes/
content.inc - Get all of the individual subtypes provided by a given content type. This would be all of the blocks for the block type, or all of the views for the view type.
File
-
includes/
content.inc, line 225
Code
function ctools_content_prepare_subtype(&$subtype, $plugin) {
foreach (array(
'path',
'js',
'css',
) as $key) {
if (!isset($subtype[$key]) && isset($plugin[$key])) {
$subtype[$key] = $plugin[$key];
}
}
// Trigger hook_ctools_content_subtype_alter().
drupal_alter('ctools_content_subtype', $subtype, $plugin);
}