Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
When a project node is deleted, the auto-generated path alias in {url_alias} is not automatically cleaned out. See #430528: Flag Form module short_path URL doesn't resolve for an example of the confusion this can cause.
Comment | File | Size | Author |
---|---|---|---|
#2 | 431326-2.delete_dead_project_url_aliases.patch | 1.33 KB | dww |
Comments
Comment #1
dwwHoly cow, there are a lot of these:
I guess we need a DB update to run a DELETE query like that. There might be a better way to write this query. ;) Suggestions for improvement welcome.
Comment #2
dwwRan this on d6.d.o and had no problems. Also tested that the URL alias is removed when I delete project nodes. Any objections?
Comment #3
dwwpath.module does this cleanup itself:
Tested and this works. We don't need the hunk in project.inc, after all.
I guess it doesn't really hurt to leave the cleanup DB update in project.install and leave this issue in this queue, but this seems most likely legacy goo from d.o badness. The newest deleted project node with a stale URL alias still in the table is node/143062 -- we have no way of knowing what version of path.module was deployed on d.o at that time, but perhaps it was something old and buggy.
Comment #4
dwwSee also #431386: URL aliases not cleaned up when projects are deleted