I downloaded the latest version of pathauto for use on my 4.6.0 Drupal, which was upgraded from 4.5.
I get this error on screen and in the log -
warning: Missing argument 4 for pathauto_create_alias() in /home/co0142/public_html/kpn/modules/pathauto/pathauto.module on line 188.
warning: Invalid argument supplied for foreach() in /home/co0142/public_html/kpn/modules/pathauto/pathauto.module on line 216.
warning: array_keys(): The first argument should be an array in /home/co0142/public_html/kpn/modules/pathauto/pathauto.module on line 231.
warning: Cannot modify header information - headers already sent by (output started at /home/co0142/public_html/kpn/includes/common.inc:384) in /home/co0142/public_html/kpn/includes/common.inc on line 192.
... when I save users.
Regards
Rick
Comments
Comment #1
mikeryanThanks for reporting this, just a dumb little missing parameter affecting people with the blog module enabled... It's fixed in 4.5 and 4.6.
Comment #2
Rick Cogley commentedOK - thanks Mike. I confirm that the initial problem has been resolved, but, now I cannot get to the general blogs path. www.mydomain.com/blog no longer works. Is that an artifact or a bug, and do you know what I can do to get it back? Seems like the aliases which were auto added (I checked the checkbox) by pathauto have changed the accessibility of this general one.
Please advise.
THanks!
Comment #3
mikeryanThe fix wouldn't have done that, but perhaps while it was broken an alias of "blog" (overriding the real blog address) was created. Check out the list of aliases on your site (administer->url aliases), if there's an alias named "blog" remove it.
Comment #4
Rick Cogley commentedThanks for the tip. I was getting errors in my log that refer to not finding a blog/0. I think the first Drupal user is #1, though, right? This is the list of my aliases that got autocreated -
blog blog/0 edit delete
blog/feed blog/0/feed edit delete
blog/jrctest blog/2 edit delete
blog/jrctest/feed blog/2/feed edit delete
blog/jrctest46-1 blog/3 edit delete
blog/jrctest46-1/feed blog/3/feed edit delete
blog/rick_cogley blog/1 edit delete
blog/rick_cogley/feed blog/1/feed edit delete
blog/[user]/feed /feed edit delete
Deleting the top two related to blog "0" fixes the problem. WHen pathauto auto-creates its paths (when you tell it to do so by checking the auto-create aliases for all blogs checkbox) does it autocreate one for 0 using some sort of a loop? Perhaps the loop could start at 1 since I think there is no blog 0.
Regards
Rick
Comment #5
mikeryanYou diagnosed it well - the user and blog bulk update operations were scanning the whole user table, and Drupal puts a dummy entry with a uid of 0 in there. I've now fixed pathauto to just do uids > 0 and committed the fix to 4.5/4.6...
Thanks!
Comment #6
Rick Cogley commentedThanks Mike. I re-installed. Will let you know if we have any issues.
--Rick
Comment #7
mikeryan