$node->created not available at bulk populate time
jerakeen - February 6, 2005 - 21:29
| Project: | |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Jump to:
Description
I've slightly changed autopath.module to add dates to the created aliases, using
$alias = "archive/".date("Y/m/d/", $node->created).$alias;
( following inspiration from http://www.codepoetry.net/archives/2005/02/06/my_drupal_code_changes.php )
This works perfectly for nodes that I create / edit normally, but I can't bulk-apply these to historical nodes for some reason - $node->title is correct for the bulk update, $node->created is blank.

#1
Kind of interesting to report a bug in your own change to a module:-). But as it turns out, prescient because I threw together a merger of autopath with Tommy Sandstrum's path_automatic which had the bug.
Until the merged module is released, you can fix your version by adding "created" to the SELECT query in _autopath_bulkupdate().
#2
I laugh at such petty social-imposed restrictions. Applied, it works, thanks very much.