See issue subject.
I found out that bug is in this code in similar_handler_argument_nid.inc:
foreach ($this->value as $nid) {
$node = node_load($nid);
if (isset($node->title) && isset($node->body) && isset($node->body[$node->language])) {
// Remove punctuation from the title.
$title = preg_replace('/[^a-z0-9 _-]+/i', '', $node->title);
Title and body should be added to the string independently. Correct code is something like this:
foreach ($this->value as $nid) {
$node = node_load($nid);
if (isset($node->title) || (isset($node->body) && isset($node->body[$node->language]))) {
// Remove punctuation from the title.
$title = preg_replace('/[^a-z0-9 _-]+/i', '', $node->title);
Comments
Comment #0.0
TonyK commentedImproved wording.
Comment #1
kedramonHi TonyK,
this is make sense, because sometimes user can remove the standart body field from node_type, and add own custom body.
Then module could not work.
Here is the patch
Comment #2
jenlamptonUpdating status.
Comment #3
jenlamptonHm, it looks like there is no longer a function
get_field_options()so this patch is going to need to be reworked. I'm also not sure this is still necessary, since the check for title and body have already been separated. Perhaps try the 7.x-2.x branch, and if the problem is resolved, we can close this issue.