Attempted to migrate terms generated by the Forum module in core, and noticed none of the paths were added.
After digging into the issue, found that the Forum module does not follow the standard convention for taxonomy terms. Rather than creating a path of taxonomy/term/tid
, it has its own format of forum/tid
.
No taxonomy/term
paths are ever created for forum containers, only those with a URL segment of forum
.
The attached patch checks if the Forum module exists and a path of forum/tid
exists, and if so, uses the path.
The module still creates an extra taxonomy/term/tid
version of the path, which it shouldn't do. I'm assuming this is due to the term.inc
code in the Migrate module, and most likely needs a patch too.
The Migrate module heavily relies on core's Taxonomy module, and makes the assumption that all taxonomy terms have a default path of taxonomy/term
. This assumption is incorrect, as these two blocks of code from core show:
/**
* Implements callback_entity_info_uri().
*/
function taxonomy_term_uri($term) {
return array(
'path' => 'taxonomy/term/' . $term->tid,
);
}
/**
* Implements callback_entity_info_uri().
*
* Entity URI callback used in forum_entity_info_alter().
*/
function forum_uri($forum) {
return array(
'path' => 'forum/' . $forum->tid,
);
}
Please review the attached patch so we can at least get the proper forum paths migrated. Thanks.
Needs review
2.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
No activities found.