[drupal-devel] [bug] node_search doesn't node_view, causing bad snippets.

Bèr Kessels drupal-devel at drupal.org
Thu Jul 28 08:32:33 UTC 2005


Issue status update for 
http://drupal.org/node/26458
Post a follow up: 
http://drupal.org/project/comments/add/26458

 Project:      Drupal
 Version:      cvs
 Component:    node.module
 Category:     bug reports
 Priority:     normal
 Assigned to:  Morbus Iff
 Reported by:  Morbus Iff
 Updated by:   Bèr Kessels
 Status:       patch

Just a thought: node_view can be extremely dynamic. so the search index
might get overrun with odd or even non-existing entries. 


Also: potentially, a node_view can return entries based on the
role/permission. parts of a body can be hidden away for certain users.
This patch will break that behaviour too.


I beleive that the search system needs some renewed thought, to
overcome such issues.




Bèr Kessels



Previous comments:
------------------------------------------------------------------------

Wed, 06 Jul 2005 15:08:32 +0000 : Morbus Iff

Attachment: http://drupal.org/files/issues/_p_nodesearch.patch (1010 bytes)

During search indexing, the node.module invokes node_view and node view
api before indexing it for content (see node_update_index). This,
however, doesn't happen on node_search, which assumes that the body
exists to get a snippet from. This causes an empty snippet on flexinode
nodes, or anything else that requires a node view api. This patch simply
adds the same block from node_update_index to node_search.




------------------------------------------------------------------------

Tue, 19 Jul 2005 14:16:50 +0000 : Morbus Iff

Attachment: http://drupal.org/files/issues/_p_26458_nodesearch.patch (996 bytes)

Updated for HEAD.




------------------------------------------------------------------------

Wed, 27 Jul 2005 20:40:06 +0000 : chx

The patch applies, does what is described and it is needed. +1







More information about the drupal-devel mailing list