[development] is nodeapi hook a requirement or not?
Peter Wolanin
pwolanin at gmail.com
Thu Mar 8 15:14:46 UTC 2007
In response to Moshe's suggestion, I'll just comment that while this
is a good idea, there needs to be more consistency or guidelines about
the way that nodes are loaded/saved for this to be sure to work with
contrib modules. I've had experience with the Clone module where some
node types expect to only be saved via the node form, and break if you
do a direct node_save():
http://drupal.org/node/119140
http://drupal.org/node/92175
-Peter
----
From: Moshe Weitzman <weitzman at tejasa.com>
To: Junyor <development at drupal.org>
Date: Thu, 08 Mar 2007 00:06:24 -0500
Subject: [development] is nodeapi hook a requirement or not?
i've bumped into a limitation in node.module that i makes me squirm. our
bulk node operations on admin/content/node are very efficient because they
perform single UPDATE statements like (make these nodes promoted):
db_query('UPDATE {node} SET status = 1, promote = 1 WHERE nid IN(%s)',
implode(',', $nodes));
the problem is that we don't let modules know about these changes via
nodeapi. so modules which listen on nodeapi('update') never know about this
change. oddly, the delete operation does do one by one deletion which is
good because we aren't leaving behind cruft in ancillary node tables.
More information about the development
mailing list